コード例 #1
0
        internal static void JoinCloudServer(
            string cloudServer,
            string username,
            string accessToken)
        {
            SaveCloudServer.ToPlasticGuiConfig(cloudServer);
            SaveCloudServer.ToPlasticGuiConfigFile(
                cloudServer, GetPlasticConfigFileToSaveOrganization());
            SaveCloudServer.ToPlasticGuiConfigFile(
                cloudServer, GetGluonConfigFileToSaveOrganization());

            KnownServers.ServersFromCloud.InitializeForWindows(
                PlasticGuiConfig.Get().Configuration.DefaultCloudServer);

            CloudEditionWelcome.WriteToTokensConf(
                cloudServer, username, accessToken);

            if (sAutoLogin)
            {
                ClientConfigData clientConfigData = ConfigurationChecker.GetClientConfigData();
                clientConfigData.WorkspaceServer = cloudServer;
                clientConfigData.WorkingMode     = SEIDWorkingMode.SSOWorkingMode.ToString();
                clientConfigData.SecurityConfig  = username;
                ClientConfig.Get().Save(clientConfigData);

                GetWindow <PlasticWindow>().GetWelcomeView().autoLoginState = AutoLogin.State.OrganizationChoosed;
            }
        }
コード例 #2
0
        internal static void JoinOrganization(string organization, string username, string accessToken)
        {
            SaveCloudServer.ToPlasticGuiConfig(organization);
            SaveCloudServer.ToPlasticGuiConfigFile(
                organization, GetPlasticConfigFileToSaveOrganization());
            SaveCloudServer.ToPlasticGuiConfigFile(
                organization, GetGluonConfigFileToSaveOrganization());

            KnownServers.ServersFromCloud.InitializeForWindows(
                PlasticGuiConfig.Get().Configuration.DefaultCloudServer);

            CloudEditionWelcome.WriteToTokensConf(
                organization,
                username,
                accessToken);

            ClientConfigData clientConfigData = ClientConfig.Get().GetClientConfigData();

            clientConfigData.WorkspaceServer = organization;
            ClientConfig.Get().Save(clientConfigData);
        }