public MainWindow()
        {
            // 设置鼠标光标到等待模式
            System.Windows.Input.Mouse.OverrideCursor = System.Windows.Input.Cursors.AppStarting;
            this.Loaded += MainWindow_Loaded;

            try
            {
                DXSplashScreen.SetState("正在启动...");

                InitializeComponent();

                /* 初始化控制板实例,该实例包含了串口通讯的协议 */
                control_central = new CControlCentral();
                control_central.ControllerCommStatusChanged += Control_central_ControllerCommStatusChanged;

                /* 初始化左侧导航栏里的按钮 */
                CPublicVariables.CureBandList = new ObservableCollection<CCureBandClass>();
                for (int i = 0; i < 8; i++)
                {
                    CPublicVariables.CureBandList.Add(new CCureBandClass(i, ref control_central));

                }
                leftNavBar.ItemCollection = CPublicVariables.CureBandList;

                // pre-load windows to accelerate the openning speed
                DXSplashScreen.SetState("加载历史记录...");
                HistoryShow frmh = new HistoryShow();
                DXSplashScreen.SetState("加载治疗信息...");
                NewCureSetup fnew = new NewCureSetup(null);
                DXSplashScreen.SetState("加载设置...");
                Setting fset = new Setting();
            }
            catch(Exception ex)
            {
                MessageBox.Show(ex.Message, "Error", MessageBoxButton.OK, MessageBoxImage.Error);
            }
            finally
            {
                // 回复鼠标光标到默认模式
                System.Windows.Input.Mouse.OverrideCursor = System.Windows.Input.Cursors.Arrow;
            }
        }
 private void btn_Setting_Click(object sender, RoutedEventArgs e)
 {
     Setting f_setting = new Setting();
     f_setting.ShowDialog();
 }