public void NewSessionBUTTON() { TopPostPlotPanel.SetActive(false); BottomPostPlotPanel.SetActive(false); TopPlotPanel.SetActive(true); BottomPlotPanel.SetActive(true); StartButton.SetActive(true); StopButton.SetActive(true); SaveDataButton.SetActive(true); NewSessionButton.SetActive(false); UsersList.patientsessioninfo.SessionDate = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); SessionDateLabel.GetComponent <Text>().text = UsersList.patientsessioninfo.SessionDate; PlayPostButton.SetActive(false); PausePostButton.SetActive(false); StopPostButton.SetActive(false); CheckNodesButton.SetActive(true); Destroy(graphGOpost); Destroy(graphGOBottompost); graphGO = Instantiate(graphPrefab) as GameObject; graphGOBottom = Instantiate(graphPrefabBottom) as GameObject; graph = graphGO.GetComponent <WMG_Axis_Graph>(); graphBottom = graphGOBottom.GetComponent <WMG_Axis_Graph>(); graph.changeSpriteParent(graphGO, TopPlotPanel); graphBottom.changeSpriteParent(graphGOBottom, BottomPlotPanel); post_plotting = false; }
void Start() { TopPlotPanel = GameObject.Find("TopPlotPanel"); BottomPlotPanel = GameObject.Find("BottomPlotPanel"); TopPostPlotPanel = GameObject.Find("TopPostPlotPanel"); TopPostPlotPanel.SetActive(false); BottomPostPlotPanel = GameObject.Find("BottomPostPlotPanel"); BottomPostPlotPanel.SetActive(false); StartButton = GameObject.Find("StartButton"); StopButton = GameObject.Find("StopButton"); SaveDataButton = GameObject.Find("SaveButton"); NewSessionButton = GameObject.Find("NewSessionButton"); SessionDateLabel = GameObject.Find("SessionTimeLabel"); NewSessionButton.SetActive(false); PlayPostButton = GameObject.Find("PlayPostButton"); PausePostButton = GameObject.Find("PausePostButton"); StopPostButton = GameObject.Find("StopPostButton"); CheckNodesButton = GameObject.Find("CheckButton"); PlayPostButton.SetActive(false); PausePostButton.SetActive(false); StopPostButton.SetActive(false); graphGO = Instantiate(graphPrefab) as GameObject; graphGOBottom = Instantiate(graphPrefabBottom) as GameObject; graph = graphGO.GetComponent <WMG_Axis_Graph>(); graphBottom = graphGOBottom.GetComponent <WMG_Axis_Graph>(); graph.changeSpriteParent(graphGO, TopPlotPanel); graphBottom.changeSpriteParent(graphGOBottom, BottomPlotPanel); graph.lineSeries[0].GetComponent <WMG_Series>().hideLines = true; graph.lineSeries[0].GetComponent <WMG_Series>().hidePoints = true; graph.lineSeries[1].GetComponent <WMG_Series>().hideLines = true; graph.lineSeries[1].GetComponent <WMG_Series>().hidePoints = true; graphBottom.lineSeries[0].GetComponent <WMG_Series>().hideLines = true; graphBottom.lineSeries[0].GetComponent <WMG_Series>().hidePoints = true; graphBottom.lineSeries[1].GetComponent <WMG_Series>().hideLines = true; graphBottom.lineSeries[1].GetComponent <WMG_Series>().hidePoints = true; PopulateLists(); InitializeDropdowns(); play_bool = false; post_plotting = false; already_played = false; UpdateFrame = PhysioThread.BodyMoveUpdateFrame; current_time = 0; delta_time = 0; }
public void StopPlotting() { s1.StopRealTimeUpdate(); s2.StopRealTimeUpdate(); s3.StopRealTimeUpdate(); s4.StopRealTimeUpdate(); StartButton.SetActive(false); StopButton.SetActive(false); NewSessionButton.SetActive(true); TopPlotPanel.SetActive(false); BottomPlotPanel.SetActive(false); TopPostPlotPanel.SetActive(true); BottomPostPlotPanel.SetActive(true); PlayPostButton.SetActive(true); PausePostButton.SetActive(false); StopPostButton.SetActive(true); CheckNodesButton.SetActive(false); PostPlotResults(); post_plotting = true; frame = 0; }
public MainControl() { InitializeComponent(); // Открытие смены NewSessionButton.Barcode = NewSessionButton.RegisterControl(((long)ActionsHelper.MainActions.NewSession), delegate(string code) { if (SessionManager.IsSessionCreated) { GuiController.CreateMessage("Смена уже открыта под пользователем " + SessionManager.WorkerName, true); return; } else { UserSelect userSelect = new UserSelect(); userSelect.ShowThisPage(); } }); ServiceButton.Barcode = ServiceButton.RegisterControl(((long)ActionsHelper.MainActions.ServiceCartridge), delegate(string code) { if (SessionManager.IsSessionCreated) { ServiceCartridge serviceCartridge = new ServiceCartridge(); serviceCartridge.ShowThisPage(); } else { GuiController.CreateMessage("Смена не открыта", true); } }); AddNewCartridgeButton.Barcode = AddNewCartridgeButton.RegisterControl(((long)ActionsHelper.MainActions.AddNewCartridge), delegate(string code) { if (SessionManager.IsSessionCreated) { AddNewCartridge addNewCartridge = new AddNewCartridge(); addNewCartridge.ShowThisPage(); } else { GuiController.CreateMessage("Смена не открыта", true); } }); ViewInfoButton.Barcode = ViewInfoButton.RegisterControl(((long)ActionsHelper.MainActions.CartridgeInfo), delegate(string code) { ShowCartridgeInfo showCartridgeInfo = new ShowCartridgeInfo(); showCartridgeInfo.ShowThisPage(); }); ViewCartridgesButton.Barcode = ((long)ActionsHelper.MainActions.PostOfficeInfo).ToString(); ViewCartridgesButton.ButtonClick += delegate(ICodeButton s, EventArgs e) { // Просмотр картриджей отделения здесь }; // Закрытие смены CloseSessionButton.Barcode = CloseSessionButton.RegisterControl(((long)ActionsHelper.MainActions.CloseSession), delegate(string code) { if (SessionManager.IsSessionCreated) { SessionManager.CloseSession(); GuiController.CreateMessage("Закрытие смены выполнено", false); } else { GuiController.CreateMessage("Смена не открыта", true); } }); // Переключение полноэкранного режима FullScreenButton.Barcode = FullScreenButton.RegisterControl(((long)ActionsHelper.MainActions.FullScreen), (c) => GuiController.MainForm.SwitchFullScreenMode()); // Выход из программы ExitButton.Barcode = ExitButton.RegisterControl(((long)ActionsHelper.MainActions.ExitApplication), (c) => GuiController.ExitApplication()); }