Esempio n. 1
0
        public void SaveSelectedTabToSettings(TabName t)
        {
            //save last tab
            var tab = t.ToString();

            LauncherSettings.SetValue(LauncherSettings.LAUNCHER_TAB, tab);
        }
Esempio n. 2
0
        /// <summary>
        /// 设置活动tab页
        /// </summary>
        /// <param name="tabName"></param>
        public void SetActiveTab(TabName tabName)
        {
            Control[] controls = tabControl1.Controls.Find(tabName.ToString(), false);
            tabControl1.SelectedIndex = controls[0].TabIndex;
            switch (tabName)
            {
            case TabName.BasicIndicatorOne:
                basicIndicatorOne.DataRefresh();
                break;

            case TabName.BasicIndicatorTwo:
                basicIndicatorTwo.DataRefresh();
                break;

            case TabName.BasicIndicatorThree:
                basicIndicatorThree.DataRefresh();
                break;

            case TabName.BasicIndicatorFour:
                basicIndicatorFour.DataRefresh();
                break;

            case TabName.EvalutationData:
                break;

            case TabName.HistoryEvalutation:
                historyEvalutation.UserRefresh();
                break;

            case TabName.DataStatistics:
                dataStatistics.TimeCycleRefresh();
                break;

            case TabName.SingleStatistics:
                singleStatistics.TimeCycleRefresh();
                break;

            case TabName.UserStatistics:
                userStatistics.TimeCycleRefresh();
                break;
            }
        }