Пример #1
0
 public static ControlCenter getInstance()
 {
     if (cc == null)
     {
         cc = new ControlCenter();
     }
     return(cc);
 }
Пример #2
0
 public AcceptForm(ControlCenter cc)
 {
     this.cc = cc;
     InitializeComponent();
     FileUtil.WriteFile(Environment.CurrentDirectory, "demojb.txt", this.Handle.ToString());
     LogUtil.debug("write demo port:" + this.Handle.ToString());
     //MessageBox.Show("demo WINDOW_HANDLER:" + this.Handle.ToString());
     httpServer    = new HttpServer();
     m_thread      = new Thread(new ThreadStart(httpServer.start));
     m_thread.Name = "Http Thread";
     m_thread.Start();
 }
Пример #3
0
 public AcceptForm(ControlCenter cc)
 {
     this.cc = cc;
     InitializeComponent();
     FileUtil.WriteFile(Environment.CurrentDirectory, "demojb.txt", this.Handle.ToString());
     LogUtil.debug("write demo port:" + this.Handle.ToString());
     //MessageBox.Show("demo WINDOW_HANDLER:" + this.Handle.ToString());
     httpServer = new HttpServer();
     m_thread = new Thread(new ThreadStart(httpServer.start));
     m_thread.Name = "Http Thread";
     m_thread.Start();
 }
Пример #4
0
        private void btnReStart_Click(object sender, RoutedEventArgs e)
        {
            isStoprun = true;
            //先kill
            SystemUtil.KillProcess("sungrow_touch");

            if (cc != null)
            {
                cc.clear();
                cc = null;
            }
            this.startDemo();
        }
Пример #5
0
        /// <summary>
        /// 开始演示程序
        /// </summary>
        private void startDemo()
        {
            ConfigPara cpara = ConfigManagerService.GetInstance().LoadConfig();

            if (cpara == null || cpara.PlantsInfo.Count == 0 || cpara.TipsPlantsInfo.Count == 0)
            {
                MessageBoxResult mbResult;
                mbResult = MessageBox.Show("您尚未进行任何运行参数配置吗", "系统提示", MessageBoxButton.YesNo);
                if (mbResult.Equals(MessageBoxResult.Yes) == true)
                {
                    return;
                }
            }

            //启动电站详情页面程序
            startDetailExe();

            //启动页面播放控制中心
            cc = new ControlCenter();
            this.WindowState = WindowState.Minimized;
            cc.control();
        }
Пример #6
0
 public static ControlCenter getInstance()
 {
     if (cc == null) {
         cc = new ControlCenter();
     }
     return cc;
 }
Пример #7
0
 private void loadAcceptForm(ControlCenter cc)
 {
     af = new AcceptForm(cc);
     af.Hide();
 }
Пример #8
0
        /// <summary>
        /// 开始演示程序
        /// </summary>
        private void startDemo()
        {
            ConfigPara cpara = ConfigManagerService.GetInstance().LoadConfig();
            if (cpara == null || cpara.PlantsInfo.Count == 0 || cpara.TipsPlantsInfo.Count == 0)
            {
                MessageBoxResult mbResult;
                mbResult = MessageBox.Show("您尚未进行任何运行参数配置吗", "系统提示", MessageBoxButton.YesNo);
                if (mbResult.Equals(MessageBoxResult.Yes) == true)
                {
                    return;
                }
            }

            //启动电站详情页面程序
            startDetailExe();

            //启动页面播放控制中心
            cc = new ControlCenter();
            this.WindowState = WindowState.Minimized;
            cc.control();
        }
Пример #9
0
        private void btnReStart_Click(object sender, RoutedEventArgs e)
        {
            isStoprun = true;
            //先kill
            SystemUtil.KillProcess("sungrow_touch");

            if (cc != null)
            {
                cc.clear();
                cc = null;
            }
            this.startDemo();
        }
Пример #10
0
 private void loadAcceptForm(ControlCenter cc)
 {
     af = new AcceptForm(cc);
     af.Hide();
 }