Ejemplo n.º 1
0
 public override void OnFetchData(Response res, int reqInstanceID)
 {
     LoadingSpinner.Hide();
     if (res.sucessful)
     {
         ShowAward(res.hashtable);
         DataLookupsCache.Instance.CacheData(res.hashtable);
         if (res.hashtable.ContainsKey("heroStats"))
         {
             LTPartnerDataManager.Instance.InitPartnerData();
         }
         mTotalNum = mTotalNum - mCurNum;
         mCurNum   = 1;
         Show();
         if (mTotalNum <= 0)
         {
             UIInventoryBagLogic.Instance.FirstItem = null;
             UIInventoryBagLogic.Instance.RefeshBag(ShowBagContent.Instance.CurType);
             controller.Close();
         }
         else
         {
             UIInventoryBagLogic.Instance.RefeshBag(ShowBagContent.Instance.CurType);
         }
     }
     else if (res.fatal)
     {
         Hub.Instance.FatalError(res.localizedError);
     }
 }
Ejemplo n.º 2
0
        public TestSceneLoadingSpinner()
        {
            LoadingSpinner loading = new LoadingSpinner(true, true);

            loading.Show();
            Add(loading);
        }
Ejemplo n.º 3
0
 public void OnRefresh(EB.Sparx.Response res)
 {
     LoadingSpinner.Hide();
     if (res.sucessful)
     {
         //界面刷新由datalookup
         if (m_RefreshCostId == "hc")
         {
             FusionTelemetry.PostBuy(((int)FusionTelemetry.UseHC.hc_resetstore).ToString(), 1, refreshBlueCostCache);
         }
         ShowRefreshPrice();
         StartCoroutine(RefreshFxPlay());
     }
     else if (res.fatal)
     {
         SparxHub.Instance.FatalError(res.localizedError);
     }
     else
     {
         MessageTemplateManager.ShowMessage(901018, null, delegate(int result)
         {
             if (result == 0)
             {
                 m_RefreshRequest.SendRequest();
                 LoadingSpinner.Show();
             }
         });
     }
     isRefresh = false;
 }
Ejemplo n.º 4
0
        public DashboardHome(MainWindow mw)
        {
            InitializeComponent();

            LoadingSpinner ls = new LoadingSpinner(mw, AppMessages.messages["data_load"]);

            try
            {
                ls.show();
                fetchAllData();
                if (ProjectConfig.projectSettings["PlanType"].ToString() == "Quick Plan")
                {
                    populateStartUpInvestment();
                    populateMarket();
                    chart3.Visible = false;
                    chart4.Visible = false;
                }
                else
                {
                    populateSalesForecast();
                    populateSalesVsCost();
                    populateExpenditure();
                    populateGrossProfit();
                }
            }
            catch (Exception e)
            {
                MessageBox.Show("Exception: " + e.Message);
            }
            finally
            {
                ls.hide();
            }
        }
Ejemplo n.º 5
0
        private IEnumerator WaitUpdataMap(System.Action callback = null, bool isCleanMove = true)
        {
            LoadingSpinner.Show();
            isWaitForUpdataMap = true;
            if (isCleanMove && moveActionList != null)
            {
                moveActionList.Clear();
            }
            bool iswait = false;

            while (LTInstanceMapModel.Instance.RequestDirQueue.Count > 0 || LTInstanceMapModel.Instance.DealDirQueue.Count > 0)
            {
                iswait = true;
                yield return(null);
            }
            while (!isNotRequest)
            {
                iswait = true;
                yield return(null);
            }

            if (iswait)//如果等待过就多等下
            {
                yield return(null);
            }

            isWaitForUpdataMap = false;
            if (callback != null)
            {
                callback();
            }
            LoadingSpinner.Hide();
            yield break;
        }
Ejemplo n.º 6
0
        private void OnBuyTimes()
        {
            if (BuyTimes >= Hotfix_LT.Data.NewGameConfigTemplateManager.Instance.GetGameConfigValue("worldBossBuyChallengeMaxTimes"))
            {
                MessageTemplateManager.ShowMessage(eMessageUIType.FloatingText, EB.Localizer.GetString("ID_codefont_in_LTResourceShopController_3145"));   //��������
                return;
            }
            float cost = Hotfix_LT.Data.NewGameConfigTemplateManager.Instance.GetGameConfigValue("worldBossBuyChallengeTimesBase") + Hotfix_LT.Data.NewGameConfigTemplateManager.Instance.GetGameConfigValue("worldBossBuyChallengeTimes") * BuyTimes;

            if (BalanceResourceUtil.GetUserDiamond() < cost)//��ʯ����
            {
                BalanceResourceUtil.HcLessMessage();
                return;
            }

            var ht = Johny.HashtablePool.Claim();

            ht.Add("0", cost);
            MessageTemplateManager.ShowMessage(902123, ht, delegate(int result) {
                if (result == 0)
                {
                    LoadingSpinner.Show();
                    BuyTimesRequest.SendRequest();
                }
            });
            Johny.HashtablePool.Release(ht);
        }
Ejemplo n.º 7
0
        public override void OnPageShown()
        {
            if (BluetoothService.Instance.ActiveModel == Model.BudsPlus)
            {
                Title.Content = Loc.GetString("selftest_header_alt");
            }
            else
            {
                Title.Content = Loc.GetString("selftest_header");
            }

            BluetoothService.Instance.SendAsync(SPPMessageBuilder.Info.RunSelfTest());
            LoadingSpinner.Visibility = Visibility.Visible;
            LoadingSpinner.Start();

            HwVer.TextDetail       = Waiting;
            SwVer.TextDetail       = Waiting;
            TouchFwVer.TextDetail  = Waiting;
            BtAddr.TextDetail      = Waiting;
            Proximity.TextDetail   = Waiting;
            Thermo.TextDetail      = Waiting;
            AdcSoc.TextDetail      = Waiting;
            AdcVoltage.TextDetail  = Waiting;
            AdcCurrent.TextDetail  = Waiting;
            Hall.TextDetail        = Waiting;
            Accelerator.TextDetail = Waiting;
            SelfTestResult.Text    = Waiting;
        }
Ejemplo n.º 8
0
        public void OnRequestResponse(EB.Sparx.Response res)
        {
            LoadingSpinner.Hide();
            if (res.sucessful)
            {
                var user = EB.Dot.Object("user", res.hashtable, null);
                if (user == null)
                {
                    Debug.LogError("Missing user object on set name!!!");
                }
                else
                {
                    LoginManager.Instance.LocalUser.Update(user);
                }

                MessageTemplateManager.ShowMessage(902045);
                DataLookupsCache.Instance.CacheData("name", InputLabel.value);
                string name = null;
                if (DataLookupsCache.Instance.SearchDataByID <string>(string.Format("mainlands.pl.{0}.un", LoginManager.Instance.LocalUserId), out name) && !string.IsNullOrEmpty(name))
                {
                    DataLookupsCache.Instance.CacheData(string.Format("mainlands.pl.{0}.un", LoginManager.Instance.LocalUserId), InputLabel.value);
                }

                if (isHadRename)
                {
                    FusionTelemetry.PostBuy(((int)FusionTelemetry.UseHC.hc_playername).ToString(), 1, (int)Hotfix_LT.Data.NewGameConfigTemplateManager.Instance.GetGameConfigValue("changeNameCost"));
                }
                controller.Close();
            }
            else
            {
                res.CheckAndShowModal();
            }
        }
Ejemplo n.º 9
0
        public void Open(int characterId, bool blockUI, System.Action <eResponseCode, Hashtable> callback)
        {
            var request = endPoint.Post("/character/open");

            request.AddData("characterId", characterId);

            if (blockUI)
            {
                LoadingSpinner.Show();
            }
            endPoint.Service(request, delegate(Response result)
            {
                if (blockUI)
                {
                    LoadingSpinner.Hide();
                }

                if (result.sucessful)
                {
                    callback(eResponseCode.Success, result.hashtable);
                    return;
                }

                callback(CheckError(result.error.ToString()), null);
            });
        }
Ejemplo n.º 10
0
        public virtual void APIStateChanged(IAPIProvider api, APIState state)
        {
            switch (state)
            {
            case APIState.Offline:
                PopContentOut(Content);
                placeholder.ScaleTo(0.8f).Then().ScaleTo(1, 3 * transform_duration, Easing.OutQuint);
                placeholder.FadeInFromZero(2 * transform_duration, Easing.OutQuint);
                LoadingSpinner.Hide();
                break;

            case APIState.Online:
                PopContentIn(Content);
                placeholder.FadeOut(transform_duration / 2, Easing.OutQuint);
                LoadingSpinner.Hide();
                break;

            case APIState.Failing:
            case APIState.Connecting:
                PopContentOut(Content);
                LoadingSpinner.Show();
                placeholder.FadeOut(transform_duration / 2, Easing.OutQuint);
                break;
            }
        }
Ejemplo n.º 11
0
 public override void OnFetchData(EB.Sparx.Response res, int reqInstanceID)
 {
     LoadingSpinner.Hide();
     if (res.sucessful)
     {
         string key       = mTaskType == eTaskType.Normal?"user_prize_data.taskliveness_reward.":"user_prize_data.taskliveness_week_reward.";
         string cachePath = key + m_CurrReceiveChest.StageData.Id;
         DataLookupsCache.Instance.CacheData(cachePath, true);
         //上传友盟获得钻石,任务
         int hcCount = 0;
         List <LTShowItemData> mlist = m_CurrReceiveChest.StageData.Awards;
         for (int i = 0; i < mlist.Count; i++)
         {
             if (mlist[i].id == "hc")
             {
                 hcCount += mlist[i].count;
             }
         }
         FusionTelemetry.PostBonus(hcCount, Umeng.GA.BonusSource.Source2);
         GlobalMenuManager.Instance.Open("LTShowRewardView", m_CurrReceiveChest.StageData.Awards);
     }
     else
     {
         res.CheckAndShowModal();
     }
 }
Ejemplo n.º 12
0
        private void Button3_Click(object sender, EventArgs e)
        {
            var cb = this.Controls.OfType <RadioButton>().FirstOrDefault(r => r.Checked);

            this.mData = cb.Text;
            AppUtilities.CreateOrUpdateDict("step7", this.mData);
            LoadingSpinner ls = new LoadingSpinner(this, AppMessages.messages["document_created"]);

            try
            {
                ls.show();
                DocumentCreator dc       = new DocumentCreator();
                string          proPath  = dc.createFinancialPackage();
                string          tempPath = Path.Combine(ProjectConfig.projectBase, "~temp_" + AppUtilities.mainData["step5"].ToString());
                ProjectLoader.load(proPath, tempPath);
                t = 1;
            }
            catch (Exception ex)
            {
                MessageBox.Show("Exception: " + ex.Message);
            }
            finally
            {
                ls.hide();
                this.Close();
                MainWindow mf = new MainWindow();
                mf.Show();
            }
        }
Ejemplo n.º 13
0
 public override void OnFetchData(EB.Sparx.Response res, int id)
 {
     LoadingSpinner.Hide();
     if (res.sucessful)
     {
         List <Hotfix_LT.Data.TimeLimitActivityStageTemplate> stageTmps = Hotfix_LT.Data.EventTemplateManager.Instance.GetTimeLimitActivityStages(ActivityId);
         if (LTHotfixManager.GetManager <TaskManager>().CurrentIndex < stageTmps.Count - 1)
         {
             LTHotfixManager.GetManager <TaskManager>().CurrentIndex++;
         }
         string cachePath;
         cachePath = "user_prize_data.taskacm_reward." + m_Chest.StageData.Id;
         DataLookupsCache.Instance.CacheData(cachePath, true);
         //上传友盟获得钻石,任务
         int hcCount = 0;
         List <LTShowItemData> mlist = m_Chest.StageData.Awards;
         for (int i = 0; i < mlist.Count; i++)
         {
             if (mlist[i].id == "hc")
             {
                 hcCount += mlist[i].count;
             }
         }
         FusionTelemetry.PostBonus(hcCount, Umeng.GA.BonusSource.Source2);
         GlobalMenuManager.Instance.Open("LTShowRewardView", m_Chest.StageData.Awards);
         UpdateChest();
     }
     else
     {
         res.CheckAndShowModal();
         //SparxHub.Instance.FatalError(res.localizedError);
     }
 }
Ejemplo n.º 14
0
        public override void OnEntering(ScreenTransitionEvent e)
        {
            base.OnEntering(e);

            LoadComponentAsync(precompiler = CreateShaderPrecompiler(), AddInternal);

            // A non-null context factory means there's still content to migrate.
            if (efContextFactory != null)
            {
                LoadComponentAsync(realmMigrator = new EFToRealmMigrator(), AddInternal);
                realmMigrator.MigrationCompleted.ContinueWith(_ => Schedule(() =>
                {
                    // Delay initial screen loading to ensure that the migration is in a complete and sane state
                    // before the intro screen may import the game intro beatmap.
                    LoadComponentAsync(loadableScreen = CreateLoadableScreen());
                }));
            }
            else
            {
                LoadComponentAsync(loadableScreen = CreateLoadableScreen());
            }

            LoadComponentAsync(spinner = new LoadingSpinner(true, true)
            {
                Anchor = Anchor.BottomRight,
                Origin = Anchor.BottomRight,
                Margin = new MarginPadding(40),
            }, _ =>
            {
                AddInternal(spinner);
                spinnerShow = Scheduler.AddDelayed(spinner.Show, 200);
            });

            checkIfLoaded();
        }
Ejemplo n.º 15
0
 private void ProcessResult(EB.Sparx.Response response, System.Action <Hashtable> dataHandler)
 {
     if (!string.IsNullOrEmpty(response.error))
     {
         if (response.error.Equals("timeout"))
         {
             MessageTemplateManager.ShowMessage(eMessageUIType.FloatingText, EB.Localizer.GetString("ID_codefont_in_LTDrawCardAPI_3009"));
             dataHandler(null);
         }
         else
         {
             UIStack.Instance.ShowLoadingScreen(delegate
             {
                 LoadingSpinner.Hide();
                 LTHotfixManager.GetManager <SceneManager>().RequestPlayState();
             }, false, true);
         }
         return;
     }
     dataHandler = dataHandler ?? new System.Action <Hashtable>(DefaultDataHandler);
     if (ProcessResponse(response))
     {
         dataHandler(response.hashtable);
     }
     else
     {
         dataHandler(null);
     }
 }
Ejemplo n.º 16
0
        private void onlineStateChanged(ValueChangedEvent <APIState> state) => Schedule(() =>
        {
            switch (state.NewValue)
            {
            case APIState.Offline:
                PopContentOut(Content);
                placeholder.ScaleTo(0.8f).Then().ScaleTo(1, 3 * transform_duration, Easing.OutQuint);
                placeholder.FadeInFromZero(2 * transform_duration, Easing.OutQuint);
                LoadingSpinner.Hide();
                break;

            case APIState.Online:
                PopContentIn(Content);
                placeholder.FadeOut(transform_duration / 2, Easing.OutQuint);
                LoadingSpinner.Hide();
                break;

            case APIState.Failing:
            case APIState.Connecting:
                PopContentOut(Content);
                LoadingSpinner.Show();
                placeholder.FadeOut(transform_duration / 2, Easing.OutQuint);
                break;
            }
        });
Ejemplo n.º 17
0
 private void SaveAsToolStripMenuItem_Click(object sender, EventArgs e)
 {
     saveFileDialog4.InitialDirectory = Environment.GetFolderPath(Environment.SpecialFolder.Desktop);
     saveFileDialog4.DefaultExt       = "bupx";
     saveFileDialog4.Filter           = "BUPX files (*.bupx)|*.bupx";
     if (saveFileDialog4.ShowDialog() == DialogResult.OK)
     {
         Debug.WriteLine(saveFileDialog4.FileName);
         LoadingSpinner ls = new LoadingSpinner(this, AppMessages.messages["project_save"]);
         try
         {
             ls.show();
             string dPath = saveFileDialog4.FileName;
             ProjectLoader.saveAsOnly(dPath, ProjectConfig.projectPath);
         }
         catch (Exception ex)
         {
             MessageBox.Show("Exception: " + ex.Message);
         }
         finally
         {
             ls.hide();
         }
     }
 }
Ejemplo n.º 18
0
        private void load()
        {
            AddRangeInternal(new Drawable[]
            {
                text = new SpriteText
                {
                    Anchor       = Anchor.Centre,
                    Origin       = Anchor.Centre,
                    Text         = "A Dance of Fire and Ice",
                    Font         = FontUsage.Default.With(size: 50),
                    Y            = -100,
                    Shadow       = true,
                    ShadowOffset = new Vector2(0, 0.15f)
                },
                new FillFlowContainer <LoadingSpinner>
                {
                    AutoSizeAxes = Axes.Both,
                    Anchor       = Anchor.Centre,
                    Origin       = Anchor.Centre,
                    Direction    = FillDirection.Horizontal,
                    Spacing      = new Vector2(20, 0),
                    Children     = new[]
                    {
                        load1 = new LoadingSpinner(true, true),
                        load2 = new LoadingSpinner(true, true),
                    }
                }
            });

            load1.Size = new Vector2(70);
            load2.Size = new Vector2(70);
        }
Ejemplo n.º 19
0
        /// <summary>
        /// Creates a default loading spinner, and then modifies it for the
        /// ProjectNavigator's purposes.  It should not be passed to the
        /// SceneNavigator; it will directly register for the events so that
        /// it can control its own visibility.  Specifically, it stays
        /// visible until the second 'will in' transition.
        /// </summary>
        /// <returns>The loading spinner.</returns>
        private LoadingSpinner CreateLoadingSpinner(GameObject loadingSpinnerPrefab = null, System.Func <int> updateProgressImpl = null)
        {
            LoadingSpinner loadingSpinner = null;

            if (loadingSpinnerPrefab)
            {
                GameObject go = Instantiate(loadingSpinnerPrefab);
                go.SetActive(false);
                loadingSpinner = go.GetComponentInChildren <LoadingSpinner>();
                if (!loadingSpinner)
                {
                    Destroy(go);
                }
            }
            loadingSpinner = loadingSpinner ?? LoadingSpinner.Create();
            loadingSpinner.transform.parent = this.transform;
            foreach (var layout in loadingSpinner.GetComponentsInChildren <SagoLayout.LayoutComponent>())
            {
                layout.ApplyOnUpdate = true;
            }

            if (updateProgressImpl != null)
            {
                loadingSpinner.IsProgressTextEnabled = true;
                loadingSpinner.UpdateProgressImpl   += updateProgressImpl;
            }
            else
            {
                loadingSpinner.IsProgressTextEnabled = false;
            }

            bool allowShutdown = false;

            System.Action <SceneController, SceneTransition> onDidOut = null;
            onDidOut = (x, y) => {
                loadingSpinner.gameObject.SetActive(true);
                SceneNavigator.Instance.OnSceneDidTransitionOut -= onDidOut;
            };
            SceneNavigator.Instance.OnSceneDidTransitionOut += onDidOut;

            System.Action <SceneController, SceneTransition> onWillIn = null;
            onWillIn = (x, y) => {
                if (loadingSpinner && allowShutdown)
                {
                    Destroy(loadingSpinner.gameObject);
                    SceneNavigator.Instance.OnSceneWillTransitionIn -= onWillIn;
                }
            };
            SceneNavigator.Instance.OnSceneWillTransitionIn += onWillIn;

            System.Action <SceneController, SceneTransition> onDidIn = null;
            onDidIn = (x, y) => {
                allowShutdown = true;
                SceneNavigator.Instance.OnSceneDidTransitionIn -= onDidIn;
            };
            SceneNavigator.Instance.OnSceneDidTransitionIn += onDidIn;

            return(loadingSpinner);
        }
Ejemplo n.º 20
0
 public void OnUse()
 {
     mUseRequest.parameters[0].parameter = curItemInfo.InventoryId.Replace("inventory.", "");
     mUseRequest.parameters[1].parameter = mCurNum.ToString();
     LoadingSpinner.Show();
     mUseRequest.SendRequest();
     dataLookup.ClearShowCache();
 }
Ejemplo n.º 21
0
 public void OnUse()
 {
     mUseRequest.parameters[0].parameter = EB.Dot.String("inventory_id", BagItemData, null);
     mUseRequest.parameters[1].parameter = EB.Dot.Integer("num", BagItemData, 0).ToString();
     LoadingSpinner.Show();
     mUseRequest.SendRequest();
     dataLookup.ClearShowCache();
 }
Ejemplo n.º 22
0
 protected void FetchDataRemote()
 {
     if (m_UIServerRequest != null)
     {
         LoadingSpinner.Show();
         m_UIServerRequest.SendRequest();
     }
 }
Ejemplo n.º 23
0
    void OnDestroy()
    {
        EB.Debug.Log("GameEngine OnDestroy");

        LoadingSpinner.UnInit();

        instance = null;
    }
Ejemplo n.º 24
0
        private void MSWordToolStripMenuItem_Click(object sender, EventArgs e)
        {
            Clipboard.Clear();
            string mssg = "";

            saveFileDialog1.InitialDirectory = Environment.GetFolderPath(Environment.SpecialFolder.Desktop);
            saveFileDialog1.DefaultExt       = "docx";
            saveFileDialog1.Filter           = "docx files (*.docx)|*.docx|All files (*.*)|*.*";
            if (saveFileDialog1.ShowDialog() == DialogResult.OK)
            {
                RichTextBox         rtb1     = new RichTextBox();
                RichTextBox         rtb2     = new RichTextBox();
                int                 seq      = 1;
                List <DocumentItem> allFiles = documentList.FindAll(x => x.Ftype == "rtf" && File.Exists(ProjectConfig.projectPath + "//" + x.DocumentName)).OrderBy(x => x.Seq).ToList();
                foreach (DocumentItem doc in allFiles)
                {
                    rtb1.LoadFile(ProjectConfig.projectPath + "\\" + doc.DocumentName);
                    rtb1.SelectAll();
                    rtb1.Copy();
                    rtb2.SelectionFont = new System.Drawing.Font("Arial", 18, FontStyle.Bold | FontStyle.Underline);
                    rtb2.AppendText("\n\n" + seq + ". " + doc.ItemName + "\n\n");
                    rtb2.SelectionFont = new System.Drawing.Font(rtb1.Font, FontStyle.Regular);
                    rtb2.Paste();
                    Clipboard.Clear();
                    seq += 1;
                }

                LoadingSpinner ls       = new LoadingSpinner(this, AppMessages.messages["exporting"]);
                string         filename = saveFileDialog1.FileName;
                try
                {
                    ls.show();
                    System.Windows.Forms.Application.DoEvents();
                    ExportGenerator document = new ExportGenerator();
                    document.open(filename);
                    document.generateCoverPage(project_name);
                    byte[] byteArray = Encoding.UTF8.GetBytes(rtb2.Rtf);
                    document.setContent(byteArray);
                    rtb1.Dispose();
                    rtb2.Dispose();
                    document.saveDocument();
                    document.Close();
                    mssg = AppMessages.messages["export_success"];
                    ls.hide();
                }
                catch (Exception ex)
                {
                    mssg = ex.Message;
                    ls.hide();
                }
                finally
                {
                    MessageBox.Show(mssg);
                    Clipboard.Clear();
                    GC.Collect();
                }
            }
        }
 private void FactoryReset_OnMouseLeftButtonUp(object sender, MouseButtonEventArgs e)
 {
     LoadingSpinner.Visibility = Visibility.Visible;
     LoadingSpinner.Start();
     BackButton.Visibility = Visibility.Hidden;
     BluetoothService.Instance.SendAsync(SPPMessageBuilder.FactoryReset());
     FactoryReset.Text      = Waiting;
     FactoryReset.IsEnabled = false;
 }
Ejemplo n.º 26
0
        void BuildComponents()
        {
            this.SetControlImage("buho",
                                 PlasticGui.Help.HelpImage.ColorBuho);

            VisualElement spinnerControl = this.Query <VisualElement>("gdSpinner").First();

            mLoadingSpinner = new LoadingSpinner();
            spinnerControl.Add(mLoadingSpinner);

            IEnumerable <string> datacenters = GetDatacenters();

            mSelectedDatacenter = datacenters.FirstOrDefault();
            mDatacenter         = new ToolbarMenu {
                text = mSelectedDatacenter
            };
            foreach (string datacenter in GetDatacenters())
            {
                mDatacenter.menu.AppendAction(datacenter, DataCenterClicked, DataCenterActive);
            }
            VisualElement datacenterContainer = this.Query <VisualElement>("datacenter").First();

            datacenterContainer.Add(mDatacenter);

            mOrganizationNameTextField    = this.Query <TextField>("orgName").First();
            mOrganizationNameNotification = this.Query <Label>("orgNameNotification").First();
            mBackButton             = this.Query <Button>("back").First();
            mCreateButton           = this.Query <Button>("create").First();
            mEncryptLearnMoreButton = this.Query <Button>("encryptLearnMore").First();
            mGettingDatacenters     = this.Query <VisualElement>("gettingDatacenters").First();

            mCreateButton.clicked += CreateButton_Clicked;

            mOrganizationNameTextField.RegisterValueChangedCallback(
                OnOrganizationNameTextFieldChanged);
            mOrganizationNameTextField.FocusOnceLoaded();

            this.SetControlText <Label>("createLabel",
                                        PlasticLocalization.Name.CreateOrganizationTitle);
            this.SetControlLabel <TextField>("orgName",
                                             PlasticLocalization.Name.OrganizationName);
            this.SetControlText <Label>("datacenterLabel",
                                        PlasticLocalization.Name.Datacenter);
            this.SetControlText <Toggle>("encryptData",
                                         PlasticLocalization.Name.EncryptionCheckButton);
            this.SetControlText <Label>("encryptExplanation",
                                        PlasticLocalization.Name.EncryptionCheckButtonExplanation, "");
            this.SetControlText <Button>("encryptLearnMore",
                                         PlasticLocalization.Name.LearnMore);
            this.SetControlText <Label>("gdLabel",
                                        PlasticLocalization.Name.GettingDatacenters);
            this.SetControlText <Button>("back",
                                         PlasticLocalization.Name.BackButton);
            this.SetControlText <Button>("create",
                                         PlasticLocalization.Name.CreateButton);
        }
 public void Reset()
 {
     Dispatcher.Invoke(() =>
     {
         LoadingSpinner.Visibility = Visibility.Hidden;
         LoadingSpinner.Stop();
         Retry.IsEnabled = true;
         Retry.Text      = "Connect";
     });
 }
Ejemplo n.º 28
0
    public int BlockService(Request request, Action <Hashtable> dataHandler)
    {
        LoadingSpinner.Show();

        return(endPoint.Service(request, delegate(Response response)
        {
            LoadingSpinner.Hide();
            ProcessResult(response, dataHandler);
        }));
    }
Ejemplo n.º 29
0
        public DownloadButton(APIBeatmapSet beatmapSet)
        {
            Icon.Icon = FontAwesome.Solid.Download;

            Content.Add(spinner = new LoadingSpinner {
                Size = new Vector2(IconSize)
            });

            this.beatmapSet = beatmapSet;
        }
Ejemplo n.º 30
0
        private int BlockService(EB.Sparx.Request request, System.Action <Hashtable> dataHandler)
        {
            LoadingSpinner.Show();

            return(endPoint.Service(request, delegate(EB.Sparx.Response response)
            {
                ProcessResult(response, dataHandler);
                LoadingSpinner.Hide();
            }));
        }