private static void ShowWindow()
		{
			Resolution currentResolution = Screen.currentResolution;
			LicenseManagementWindow.left = (currentResolution.width - LicenseManagementWindow.width) / 2;
			LicenseManagementWindow.top = (currentResolution.height - LicenseManagementWindow.height) / 2;
			LicenseManagementWindow.windowArea = new Rect((float)LicenseManagementWindow.left, (float)LicenseManagementWindow.top, (float)LicenseManagementWindow.width, (float)LicenseManagementWindow.height);
			LicenseManagementWindow.win = LicenseManagementWindow.Window;
			LicenseManagementWindow.win.position = LicenseManagementWindow.windowArea;
			LicenseManagementWindow.win.Show();
		}
Beispiel #2
0
        private static void ShowWindow()
        {
            Resolution currentResolution = Screen.currentResolution;

            LicenseManagementWindow.left         = (currentResolution.width - LicenseManagementWindow.width) / 2;
            LicenseManagementWindow.top          = (currentResolution.height - LicenseManagementWindow.height) / 2;
            LicenseManagementWindow.windowArea   = new Rect((float)LicenseManagementWindow.left, (float)LicenseManagementWindow.top, (float)LicenseManagementWindow.width, (float)LicenseManagementWindow.height);
            LicenseManagementWindow.win          = LicenseManagementWindow.Window;
            LicenseManagementWindow.win.position = LicenseManagementWindow.windowArea;
            LicenseManagementWindow.win.Show();
        }
Beispiel #3
0
        static void ShowWindow()
        {
            Resolution res = Screen.currentResolution;

            left         = (res.width - width) / 2;
            top          = (res.height - height) / 2;
            windowArea   = new Rect(left, top, width, height);
            win          = Window;
            win.position = windowArea;
            win.Show();
        }
        private static void ShowWindow()
        {
            Resolution currentResolution = Screen.currentResolution;

            left         = (currentResolution.width - width) / 2;
            top          = (currentResolution.height - height) / 2;
            windowArea   = new Rect((float)left, (float)top, (float)width, (float)height);
            win          = Window;
            win.position = windowArea;
            win.Show();
        }
Beispiel #5
0
 private void OnGUI()
 {
     GUILayout.BeginArea(LicenseManagementWindow.rectArea);
     GUILayout.FlexibleSpace();
     GUILayout.BeginHorizontal(new GUILayoutOption[0]);
     if (GUILayout.Button("Check for updates", new GUILayoutOption[]
     {
         GUILayout.ExpandHeight(true),
         GUILayout.Width((float)LicenseManagementWindow.buttonWidth)
     }))
     {
         LicenseManagementWindow.CheckForUpdates();
     }
     GUI.skin.label.wordWrap = true;
     GUILayout.Label("Checks for updates to the currently installed license. If you have purchased addons you can install them by pressing this button (Internet access required)", new GUILayoutOption[0]);
     GUILayout.EndHorizontal();
     GUILayout.Space(15f);
     GUILayout.BeginHorizontal(new GUILayoutOption[0]);
     if (GUILayout.Button("Activate new license", new GUILayoutOption[]
     {
         GUILayout.ExpandHeight(true),
         GUILayout.Width((float)LicenseManagementWindow.buttonWidth)
     }))
     {
         LicenseManagementWindow.ActivateNewLicense();
         LicenseManagementWindow.Window.Close();
     }
     GUILayout.Label("Activate Unity with a different serial number, switch to a free serial or start a trial period if you are eligible for it (Internet access required).", new GUILayoutOption[0]);
     GUILayout.EndHorizontal();
     GUILayout.Space(15f);
     GUILayout.BeginHorizontal(new GUILayoutOption[0]);
     if (GUILayout.Button("Return license", new GUILayoutOption[]
     {
         GUILayout.ExpandHeight(true),
         GUILayout.Width((float)LicenseManagementWindow.buttonWidth)
     }))
     {
         LicenseManagementWindow.ReturnLicense();
     }
     GUILayout.Label("Return this license and free an activation for the serial it is using. You can then reuse the activation on another machine (Internet access required).", new GUILayoutOption[0]);
     GUILayout.EndHorizontal();
     GUILayout.Space(15f);
     GUILayout.BeginHorizontal(new GUILayoutOption[0]);
     if (GUILayout.Button("Manual activation", new GUILayoutOption[]
     {
         GUILayout.ExpandHeight(true),
         GUILayout.Width((float)LicenseManagementWindow.buttonWidth)
     }))
     {
         LicenseManagementWindow.ManualActivation();
     }
     GUILayout.Label("Start the manual activation process, you can save this machines license activation request file or deploy a license file you have already activated manually.", new GUILayoutOption[0]);
     GUILayout.EndHorizontal();
     GUILayout.Space(15f);
     GUILayout.BeginHorizontal(new GUILayoutOption[0]);
     if (GUILayout.Button("Unity FAQ", new GUILayoutOption[]
     {
         GUILayout.ExpandHeight(true),
         GUILayout.Width((float)LicenseManagementWindow.buttonWidth)
     }))
     {
         Application.OpenURL("http://unity3d.com/unity/faq");
     }
     GUILayout.Label("Open the Unity FAQ web page, where you can find information about Unity's license system.", new GUILayoutOption[0]);
     GUILayout.EndHorizontal();
     GUILayout.FlexibleSpace();
     GUILayout.EndArea();
 }
 private static void ShowWindow()
 {
     Resolution currentResolution = Screen.currentResolution;
     left = (currentResolution.width - width) / 2;
     top = (currentResolution.height - height) / 2;
     windowArea = new Rect((float) left, (float) top, (float) width, (float) height);
     win = Window;
     win.position = windowArea;
     win.Show();
 }