Track() private method

private Track ( string page ) : void
page string
return void
示例#1
0
 private static void DoShowWelcomeScreen(string how)
 {
     ++WelcomeScreen.s_ShowCount;
     EditorPrefs.SetInt("WelcomeScreenShowCount", WelcomeScreen.s_ShowCount);
     Analytics.Track(string.Format("/WelcomeScreen/Show/{0}/{1}", (object)how, (object)WelcomeScreen.s_ShowCount));
     EditorWindow.GetWindowWithRect <WelcomeScreen>(new Rect(0.0f, 0.0f, 570f, 440f), true, "Welcome To Unity");
 }
示例#2
0
 private void DoBake()
 {
     Analytics.Track("/LightMapper/Start");
     Analytics.Event("LightMapper", "Mode", LightmapSettings.lightmapsMode.ToString(), 1);
     Analytics.Event("LightMapper", "Button", "BakeScene", 1);
     Lightmapping.BakeAsync();
 }
 public static void OpenItemInAssetStore(AssetStoreAsset activeAsset)
 {
     if (activeAsset.id != 0)
     {
         AssetStore.Open(string.Format("content/{0}?assetID={1}", activeAsset.packageID, activeAsset.id));
         Analytics.Track(string.Format("/AssetStore/ViewInStore/{0}/{1}", activeAsset.packageID, activeAsset.id));
     }
 }
示例#4
0
        public static void ShowAssetStoreLoginWindow(string loginReason, AssetStoreLoginWindow.LoginCallback callback)
        {
            AssetStoreLoginWindow windowWithRect = EditorWindow.GetWindowWithRect <AssetStoreLoginWindow>(new Rect(100f, 100f, 360f, 140f), true, "Login to Asset Store");

            windowWithRect.position = new Rect(100f, 100f, windowWithRect.position.width, windowWithRect.position.height);
            windowWithRect.m_Parent.window.m_DontSaveToLayout = true;
            windowWithRect.m_Password           = string.Empty;
            windowWithRect.m_LoginCallback      = callback;
            windowWithRect.m_LoginReason        = loginReason;
            windowWithRect.m_LoginRemoteMessage = (string)null;
            Analytics.Track("/AssetStore/Login");
        }
示例#5
0
        public static void ShowAssetStoreInstaBuyWindowBuilding(AssetStoreAsset asset)
        {
            AssetStoreInstaBuyWindow assetStoreInstaBuyWindow = AssetStoreInstaBuyWindow.ShowAssetStoreInstaBuyWindow(asset, string.Empty, string.Empty, string.Empty, string.Empty);

            if (assetStoreInstaBuyWindow.m_Purchasing != AssetStoreInstaBuyWindow.PurchaseStatus.Init)
            {
                EditorUtility.DisplayDialog("Download in progress", "There is already a package download in progress. You can only have one download running at a time", "Close");
                return;
            }
            assetStoreInstaBuyWindow.m_Purchasing    = AssetStoreInstaBuyWindow.PurchaseStatus.StartBuild;
            assetStoreInstaBuyWindow.m_BuildAttempts = 1;
            asset.previewInfo.buildProgress          = 0f;
            Analytics.Track(string.Format("/AssetStore/ShowInstaFree/{0}/{1}", assetStoreInstaBuyWindow.m_Asset.packageID, assetStoreInstaBuyWindow.m_Asset.id));
        }
示例#6
0
        private void PurchaseDeclinedGUI()
        {
            AssetStoreAsset.PreviewInfo previewInfo = this.m_Asset.previewInfo;
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.Space(5f);
            GUILayout.Label(AssetStoreInstaBuyWindow.s_AssetStoreLogo, GUIStyle.none, new GUILayoutOption[]
            {
                GUILayout.ExpandWidth(false)
            });
            GUILayout.BeginVertical(new GUILayoutOption[0]);
            GUILayout.Label("Purchase declined", EditorStyles.boldLabel, new GUILayoutOption[0]);
            GUILayout.Label("No money has been drawn from you credit card", new GUILayoutOption[0]);
            bool  flag = this.m_Message != null && this.m_Message != string.Empty;
            float num  = (float)(160 + ((!flag) ? 0 : 20));

            if (num != base.position.height)
            {
                base.position = new Rect(base.position.x, base.position.y, base.position.width, num);
            }
            if (flag)
            {
                GUILayout.Label(this.m_Message, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
            }
            GUILayout.Label("Package: " + previewInfo.packageName, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
            GUILayout.EndVertical();
            GUILayout.Space(5f);
            GUILayout.EndHorizontal();
            GUILayout.FlexibleSpace();
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.Space(8f);
            GUILayout.FlexibleSpace();
            if (GUILayout.Button("Close", new GUILayoutOption[0]))
            {
                Analytics.Track(string.Format("/AssetStore/DeclinedAbort/{0}/{1}", this.m_Asset.packageID, this.m_Asset.id));
                this.m_Asset = null;
                base.Close();
            }
            GUILayout.Space(5f);
            if (GUILayout.Button("Put to basket", new GUILayoutOption[0]))
            {
                AssetStore.Open(string.Format("content/{0}/basketpurchase", this.m_Asset.packageID));
                Analytics.Track(string.Format("/AssetStore/DeclinedPutToBasket/{0}/{1}", this.m_Asset.packageID, this.m_Asset.id));
                this.m_Asset = null;
                base.Close();
            }
            GUILayout.Space(5f);
            GUILayout.EndHorizontal();
            GUILayout.Space(5f);
        }
示例#7
0
        private void PurchaseSuccessGUI()
        {
            AssetStoreAsset.PreviewInfo previewInfo = this.m_Asset.previewInfo;
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.Space(5f);
            GUILayout.Label(AssetStoreInstaBuyWindow.s_AssetStoreLogo, GUIStyle.none, new GUILayoutOption[]
            {
                GUILayout.ExpandWidth(false)
            });
            GUILayout.BeginVertical(new GUILayoutOption[0]);
            GUILayout.Label("Purchase completed succesfully", EditorStyles.boldLabel, new GUILayoutOption[0]);
            GUILayout.Label("You will receive a receipt in your email soon.", new GUILayoutOption[0]);
            bool  flag = this.m_Message != null && this.m_Message != string.Empty;
            float num  = (float)(160 + ((!flag) ? 0 : 20));

            if (num != base.position.height)
            {
                base.position = new Rect(base.position.x, base.position.y, base.position.width, num);
            }
            if (flag)
            {
                GUILayout.Label(this.m_Message, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
            }
            GUILayout.Label("Package: " + previewInfo.packageName, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
            GUILayout.EndVertical();
            GUILayout.Space(5f);
            GUILayout.EndHorizontal();
            GUILayout.FlexibleSpace();
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.Space(8f);
            GUILayout.FlexibleSpace();
            if (GUILayout.Button("Close", new GUILayoutOption[0]))
            {
                Analytics.Track(string.Format("/AssetStore/PurchaseOk/{0}/{1}", this.m_Asset.packageID, this.m_Asset.id));
                this.m_Asset = null;
                base.Close();
            }
            GUILayout.Space(5f);
            if (GUILayout.Button("Import package", new GUILayoutOption[0]))
            {
                Analytics.Track(string.Format("/AssetStore/PurchaseOkImport/{0}/{1}", this.m_Asset.packageID, this.m_Asset.id));
                this.m_BuildAttempts = 1;
                this.m_Asset.previewInfo.buildProgress = 0f;
                this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.StartBuild;
            }
            GUILayout.Space(5f);
            GUILayout.EndHorizontal();
            GUILayout.Space(5f);
        }
示例#8
0
 public void OnGUI()
 {
     WelcomeScreen.LoadLogos();
     GUILayout.BeginVertical(new GUILayoutOption[0]);
     GUI.Box(new Rect(13f, 8f, (float)WelcomeScreen.styles.unityLogo.image.width, (float)WelcomeScreen.styles.unityLogo.image.height), WelcomeScreen.styles.unityLogo, GUIStyle.none);
     GUILayout.Space(15f);
     GUILayout.BeginHorizontal(new GUILayoutOption[0]);
     GUILayout.Space(120f);
     GUILayout.BeginVertical(new GUILayoutOption[0]);
     GUILayout.Label(WelcomeScreen.styles.mainHeader, new GUILayoutOption[0]);
     GUILayout.Label(WelcomeScreen.styles.mainText, "WordWrappedLabel", new GUILayoutOption[]
     {
         GUILayout.Width(300f)
     });
     GUILayout.EndVertical();
     GUILayout.EndHorizontal();
     GUILayout.Space(8f);
     this.ShowEntry(WelcomeScreen.styles.videoTutLogo, "http://unity3d.com/learn/tutorials/modules/", WelcomeScreen.styles.videoTutHeader, WelcomeScreen.styles.videoTutText, "VideoTutorials");
     this.ShowEntry(WelcomeScreen.styles.unityBasicsLogo, "file:///unity/Manual/UnityBasics.html", WelcomeScreen.styles.unityBasicsHeader, WelcomeScreen.styles.unityBasicsText, "UnityBasics");
     this.ShowEntry(WelcomeScreen.styles.unityAnswersLogo, "http://answers.unity3d.com/", WelcomeScreen.styles.unityAnswersHeader, WelcomeScreen.styles.unityAnswersText, "UnityAnswers");
     this.ShowEntry(WelcomeScreen.styles.unityForumLogo, "http://forum.unity3d.com/", WelcomeScreen.styles.unityForumHeader, WelcomeScreen.styles.unityForumText, "UnityForum");
     this.ShowEntry(WelcomeScreen.styles.assetStoreLogo, "home/?ref=http%3a%2f%2fUnityEditor.unity3d.com%2fWelcomeScreen", WelcomeScreen.styles.assetStoreHeader, WelcomeScreen.styles.assetStoreText, "AssetStore");
     GUILayout.FlexibleSpace();
     GUILayout.BeginHorizontal(new GUILayoutOption[]
     {
         GUILayout.Height(20f)
     });
     GUILayout.FlexibleSpace();
     GUI.changed = false;
     WelcomeScreen.s_ShowAtStartup = GUILayout.Toggle(WelcomeScreen.s_ShowAtStartup, WelcomeScreen.styles.showAtStartupText, new GUILayoutOption[0]);
     if (GUI.changed)
     {
         EditorPrefs.SetInt("ShowWelcomeAtStartup4", (!WelcomeScreen.s_ShowAtStartup) ? 0 : 1);
         if (WelcomeScreen.s_ShowAtStartup)
         {
             Analytics.Track(string.Format("/WelcomeScreen/EnableAtStartup/{0}", WelcomeScreen.s_ShowCount));
         }
         else
         {
             Analytics.Track(string.Format("/WelcomeScreen/DisableAtStartup/{0}", WelcomeScreen.s_ShowCount));
         }
         WelcomeScreen.s_ShowCount = 0;
         EditorPrefs.SetInt("WelcomeScreenShowCount", 0);
     }
     GUILayout.Space(10f);
     GUILayout.EndHorizontal();
     GUILayout.EndVertical();
 }
示例#9
0
 private void ShowHelpPageOrBrowseURL(string url, string analyticsAction)
 {
     Analytics.Track(string.Format("/WelcomeScreen/OpenURL/{0}/{1}", analyticsAction, WelcomeScreen.s_ShowCount));
     if (url.StartsWith("file"))
     {
         Help.ShowHelpPage(url);
     }
     else if (url.StartsWith("home/"))
     {
         AssetStore.Open(url);
         GUIUtility.ExitGUI();
     }
     else
     {
         Help.BrowseURL(url);
     }
 }
示例#10
0
        private void Buttons()
        {
            bool flag = Lightmapping.giWorkflowMode == Lightmapping.GIWorkflowMode.Iterative;

            if (flag)
            {
                EditorGUILayout.HelpBox("Baking of lightmaps is automatic because the workflow mode is set to 'Auto'. The lightmap data is stored in the GI cache.", MessageType.Info);
            }
            if (Lightmapping.lightingDataAsset && !Lightmapping.lightingDataAsset.isValid)
            {
                EditorGUILayout.HelpBox(Lightmapping.lightingDataAsset.validityErrorMessage, MessageType.Error);
            }
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.FlexibleSpace();
            EditorGUI.BeginChangeCheck();
            flag = GUILayout.Toggle(flag, LightingWindow.styles.ContinuousBakeLabel, new GUILayoutOption[0]);
            if (EditorGUI.EndChangeCheck())
            {
                Lightmapping.giWorkflowMode = ((!flag) ? Lightmapping.GIWorkflowMode.OnDemand : Lightmapping.GIWorkflowMode.Iterative);
                InspectorWindow.RepaintAllInspectors();
            }
            using (new EditorGUI.DisabledScope(flag))
            {
                bool flag2 = flag || !Lightmapping.isRunning;
                if (flag2)
                {
                    if (EditorGUI.ButtonWithDropdownList(LightingWindow.styles.BuildLabel, LightingWindow.s_BakeModeOptions, new GenericMenu.MenuFunction2(this.BakeDropDownCallback), new GUILayoutOption[]
                    {
                        GUILayout.Width(180f)
                    }))
                    {
                        this.DoBake();
                        GUIUtility.ExitGUI();
                    }
                }
                else if (GUILayout.Button("Cancel", new GUILayoutOption[]
                {
                    GUILayout.Width(this.kButtonWidth)
                }))
                {
                    Lightmapping.Cancel();
                    Analytics.Track("/LightMapper/Cancel");
                }
            }
            GUILayout.EndHorizontal();
        }
示例#11
0
        private void Buttons()
        {
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.FlexibleSpace();
            EditorGUI.BeginChangeCheck();
            bool flag = Lightmapping.giWorkflowMode == Lightmapping.GIWorkflowMode.Iterative;

            flag = GUILayout.Toggle(flag, LightingWindow.styles.ContinuousBakeLabel, new GUILayoutOption[0]);
            if (EditorGUI.EndChangeCheck())
            {
                Lightmapping.giWorkflowMode = ((!flag) ? Lightmapping.GIWorkflowMode.OnDemand : Lightmapping.GIWorkflowMode.Iterative);
                InspectorWindow.RepaintAllInspectors();
            }
            EditorGUI.BeginDisabledGroup(flag);
            bool flag2 = flag || !Lightmapping.isRunning;

            if (flag2)
            {
                if (EditorGUI.ButtonWithDropdownList(LightingWindow.styles.BuildLabel, LightingWindow.s_BakeModeOptions, new GenericMenu.MenuFunction2(this.BakeDropDownCallback), new GUILayoutOption[]
                {
                    GUILayout.Width(180f)
                }))
                {
                    this.DoBake();
                    GUIUtility.ExitGUI();
                }
            }
            else
            {
                if (GUILayout.Button("Cancel", new GUILayoutOption[]
                {
                    GUILayout.Width(this.kButtonWidth)
                }))
                {
                    Lightmapping.Cancel();
                    Analytics.Track("/LightMapper/Cancel");
                }
            }
            EditorGUI.EndDisabledGroup();
            GUILayout.EndHorizontal();
        }
示例#12
0
        private void Buttons()
        {
            bool flag = Lightmapping.giWorkflowMode == Lightmapping.GIWorkflowMode.Iterative;

            if (flag)
            {
                EditorGUILayout.HelpBox("Baking of lightmaps is automatic because the workflow mode is set to 'Auto'. The lightmap data is stored in the GI cache.", MessageType.Info);
            }
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.FlexibleSpace();
            EditorGUI.BeginChangeCheck();
            flag = GUILayout.Toggle(flag, styles.ContinuousBakeLabel, new GUILayoutOption[0]);
            if (EditorGUI.EndChangeCheck())
            {
                Lightmapping.giWorkflowMode = !flag ? Lightmapping.GIWorkflowMode.OnDemand : Lightmapping.GIWorkflowMode.Iterative;
                InspectorWindow.RepaintAllInspectors();
            }
            EditorGUI.BeginDisabledGroup(flag);
            if (flag || !Lightmapping.isRunning)
            {
                GUILayoutOption[] options = new GUILayoutOption[] { GUILayout.Width(180f) };
                if (EditorGUI.ButtonWithDropdownList(styles.BuildLabel, s_BakeModeOptions, new GenericMenu.MenuFunction2(this.BakeDropDownCallback), options))
                {
                    this.DoBake();
                    GUIUtility.ExitGUI();
                }
            }
            else
            {
                GUILayoutOption[] optionArray2 = new GUILayoutOption[] { GUILayout.Width(this.kButtonWidth) };
                if (GUILayout.Button("Cancel", optionArray2))
                {
                    Lightmapping.Cancel();
                    Analytics.Track("/LightMapper/Cancel");
                }
            }
            EditorGUI.EndDisabledGroup();
            GUILayout.EndHorizontal();
        }
示例#13
0
        public static AssetStoreInstaBuyWindow ShowAssetStoreInstaBuyWindow(AssetStoreAsset asset, string purchaseMessage, string paymentMethodCard, string paymentMethodExpire, string priceText)
        {
            AssetStoreInstaBuyWindow windowWithRect = EditorWindow.GetWindowWithRect <AssetStoreInstaBuyWindow>(new Rect(100f, 100f, 400f, 160f), true, "Buy package from Asset Store");

            if (windowWithRect.m_Purchasing != AssetStoreInstaBuyWindow.PurchaseStatus.Init)
            {
                EditorUtility.DisplayDialog("Download in progress", "There is already a package download in progress. You can only have one download running at a time", "Close");
                return(windowWithRect);
            }
            windowWithRect.position = new Rect(100f, 100f, 400f, 160f);
            windowWithRect.m_Parent.window.m_DontSaveToLayout = true;
            windowWithRect.m_Asset      = asset;
            windowWithRect.m_Password   = string.Empty;
            windowWithRect.m_Message    = string.Empty;
            windowWithRect.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.Init;
            windowWithRect.m_NextAllowedBuildRequestTime = 0.0;
            windowWithRect.m_BuildAttempts       = 0;
            windowWithRect.m_PurchaseMessage     = purchaseMessage;
            windowWithRect.m_PaymentMethodCard   = paymentMethodCard;
            windowWithRect.m_PaymentMethodExpire = paymentMethodExpire;
            windowWithRect.m_PriceText           = priceText;
            Analytics.Track(string.Format("/AssetStore/ShowInstaBuy/{0}/{1}", windowWithRect.m_Asset.packageID, windowWithRect.m_Asset.id));
            return(windowWithRect);
        }
示例#14
0
 private void DoBakeReflectionProbes()
 {
     Lightmapping.BakeAllReflectionProbesSnapshots();
     Analytics.Track("/LightMapper/BakeAllReflectionProbesSnapshots");
 }
示例#15
0
 private void DoClear()
 {
     Lightmapping.Clear();
     Analytics.Track("/LightMapper/Clear");
 }
示例#16
0
 private void DoClear()
 {
     Lightmapping.ClearLightingDataAsset();
     Lightmapping.Clear();
     Analytics.Track("/LightMapper/Clear");
 }
示例#17
0
        private void CompletePurchase()
        {
            this.m_Message = string.Empty;
            string password = this.m_Password;

            this.m_Password   = string.Empty;
            this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.InProgress;
            AssetStoreClient.DirectPurchase(this.m_Asset.packageID, password, delegate(PurchaseResult result)
            {
                this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.Init;
                if (result.error != null)
                {
                    this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.Declined;
                    this.m_Message    = "An error occured while completing you purhase.";
                    base.Close();
                }
                string text = null;
                switch (result.status)
                {
                case PurchaseResult.Status.BasketNotEmpty:
                    this.m_Message    = "Something else has been put in our Asset Store basket while doing this purchase.";
                    this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.Declined;
                    break;

                case PurchaseResult.Status.ServiceDisabled:
                    this.m_Message    = "Single click purchase has been disabled while doing this purchase.";
                    this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.Declined;
                    break;

                case PurchaseResult.Status.AnonymousUser:
                    this.m_Message    = "You have been logged out from somewhere else while doing this purchase.";
                    this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.Declined;
                    break;

                case PurchaseResult.Status.PasswordMissing:
                    this.m_Message = result.message;
                    base.Repaint();
                    break;

                case PurchaseResult.Status.PasswordWrong:
                    this.m_Message = result.message;
                    base.Repaint();
                    break;

                case PurchaseResult.Status.PurchaseDeclined:
                    this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.Declined;
                    if (result.message != null)
                    {
                        this.m_Message = result.message;
                    }
                    base.Repaint();
                    break;

                case PurchaseResult.Status.Ok:
                    this.m_Purchasing = AssetStoreInstaBuyWindow.PurchaseStatus.Complete;
                    if (result.message != null)
                    {
                        this.m_Message = result.message;
                    }
                    base.Repaint();
                    break;
                }
                if (text != null)
                {
                    EditorUtility.DisplayDialog("Purchase failed", text + " This purchase has been cancelled.", "Add this item to basket", "Cancel");
                }
            });
            Analytics.Track(string.Format("/AssetStore/InstaBuy/{0}/{1}", this.m_Asset.packageID, this.m_Asset.id));
        }
示例#18
0
        private void PasswordGUI()
        {
            AssetStoreAsset.PreviewInfo previewInfo = this.m_Asset.previewInfo;
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.Space(5f);
            GUILayout.Label(AssetStoreInstaBuyWindow.s_AssetStoreLogo, GUIStyle.none, new GUILayoutOption[]
            {
                GUILayout.ExpandWidth(false)
            });
            GUILayout.BeginVertical(new GUILayoutOption[0]);
            GUILayout.Label("Complete purchase by entering your AssetStore password", EditorStyles.boldLabel, new GUILayoutOption[0]);
            bool  flag  = this.m_PurchaseMessage != null && this.m_PurchaseMessage != string.Empty;
            bool  flag2 = this.m_Message != null && this.m_Message != string.Empty;
            float num   = (float)(160 + ((!flag) ? 0 : 20) + ((!flag2) ? 0 : 20));

            if (num != base.position.height)
            {
                base.position = new Rect(base.position.x, base.position.y, base.position.width, num);
            }
            if (flag)
            {
                GUILayout.Label(this.m_PurchaseMessage, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
            }
            if (flag2)
            {
                Color color = GUI.color;
                GUI.color = Color.red;
                GUILayout.Label(this.m_Message, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
                GUI.color = color;
            }
            GUILayout.Label("Package: " + previewInfo.packageName, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
            string text = string.Format("Credit card: {0} (expires {1})", this.m_PaymentMethodCard, this.m_PaymentMethodExpire);

            GUILayout.Label(text, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
            GUILayout.Space(8f);
            EditorGUILayout.LabelField("Amount", this.m_PriceText, new GUILayoutOption[0]);
            this.m_Password = EditorGUILayout.PasswordField("Password", this.m_Password, new GUILayoutOption[0]);
            GUILayout.EndVertical();
            GUILayout.Space(5f);
            GUILayout.EndHorizontal();
            GUILayout.FlexibleSpace();
            GUILayout.BeginHorizontal(new GUILayoutOption[0]);
            GUILayout.Space(8f);
            if (GUILayout.Button("Just put to basket...", new GUILayoutOption[0]))
            {
                AssetStore.Open(string.Format("content/{0}/basketpurchase", this.m_Asset.packageID));
                Analytics.Track(string.Format("/AssetStore/PutToBasket/{0}/{1}", this.m_Asset.packageID, this.m_Asset.id));
                this.m_Asset = null;
                base.Close();
                GUIUtility.ExitGUI();
            }
            GUILayout.FlexibleSpace();
            if (GUILayout.Button("Cancel", new GUILayoutOption[0]))
            {
                Analytics.Track(string.Format("/AssetStore/CancelInstaBuy/{0}/{1}", this.m_Asset.packageID, this.m_Asset.id));
                this.m_Asset = null;
                base.Close();
                GUIUtility.ExitGUI();
            }
            GUILayout.Space(5f);
            if (GUILayout.Button("Complete purchase", new GUILayoutOption[0]))
            {
                this.CompletePurchase();
            }
            GUILayout.Space(5f);
            GUILayout.EndHorizontal();
            GUILayout.Space(5f);
        }