public bool UnInitialize() { lock (this) { HostUnInitialize(); _platform = null; } return(true); }
public bool Initialize(FxpaBase platform) { lock (this) { _platform = platform; //HostInitialize(new List<ArbiterClientId?>(new ArbiterClientId? [] { _platform.SubscriptionClientID } )); HostInitialize(); } return(true); }
public bool Initialize(FxpaBase platform) { //SystemMonitor.CheckThrow(_platform == null); if (OnInitialize(platform) == false) { return(false); } fxpaBase = platform; return(true); }
public bool UnInitialize() { if (IsInitialized == false) { return(true); } bool result = OnUnInitialize(); fxpaBase = null; return(result); }
public bool UnInitialize() { if (IsInitialized == false) { return(true); } bool result = OnUnInitialize(); _platform = null; return(result); }
void LoadPlatform(FxpaBase platform) { fxpaBaseForm = platform; if (fxpaBaseForm != null) { fxpaBaseForm.ActiveComponentUpdateEvent += new FxpaBase.ActiveComponentUpdateDelegate(platform_ActiveComponentUpdateEvent); fxpaBaseForm.Initialize(Settings.Default); } if (fxpaBaseForm != null) { this.Text = "FXPA"; //this.skinEngine1.SkinFile = "skin/default.ssk"; UpdateToolsMenu(); UpdateViewMenu(); UpdateComponentsMenu(); //signalHandler.SignalListView = signalListView; //signalHandler.StatListView = statListView; //signalListHandler.SignalListView = signalListView; //signalListHandler.StatListView = statListView; //AppContext.SignalHandler = signalHandler; //AppContext.SignalListHandler = signalListHandler; AppContext.SignalListView = signalListView; AppContext.StatListView = statListView; AppContext.FxpaMain = this; //InfoPublishForm infoPublishForm = new InfoPublishForm(); //AppContext.InfoPublishHandler.InfoListView = this.infoListView; DataService.Initialze(); SetupDefaultPlatform(); //timeCheckHandler.FXPA = this; //timeCheckHandler.SignalListView = signalListView; //timeCheckHandler.InfoListView = infoListView; //AppContext.TimeCheckHandler = timeCheckHandler; //AppClient.RegisterHandler(Protocol.S0002_1, timeCheckHandler); //AppClient.RegisterHandler(Protocol.C0001_4, logOutHandler); } }
private void FxpaMainForm_FormClosing(object sender, FormClosingEventArgs e) { DialogResult dialogResult = MessageBox.Show("Are you sure to exit? ", "Exit", MessageBoxButtons.OKCancel, MessageBoxIcon.Question); if (dialogResult == DialogResult.OK) { //logOutHandler.Execute(); LogUtil.Info("Client Close"); fxpaBaseForm.UnInitialize(); fxpaBaseForm.ActiveComponentUpdateEvent -= new FxpaBase.ActiveComponentUpdateDelegate(platform_ActiveComponentUpdateEvent); fxpaBaseForm = null; Application.ExitThread(); } else { e.Cancel = true; } }
private void menuItemExit_Click(object sender, EventArgs e) { //if (_platform != null) //{ // _platform.UnInitialize(); // _platform.ActiveComponentUpdateEvent -= new Platform.ActiveComponentUpdateDelegate(platform_ActiveComponentUpdateEvent); // _platform = null; // tabControl.TabPages.Clear(); // this.Close(); //} DialogResult dialogResult = MessageBox.Show("Are you sure to exit? ", "Exit", MessageBoxButtons.OKCancel, MessageBoxIcon.Question); if (dialogResult == DialogResult.OK) { //logOutHandler.Execute(); LogUtil.Info("Client Close"); fxpaBaseForm.UnInitialize(); fxpaBaseForm.ActiveComponentUpdateEvent -= new FxpaBase.ActiveComponentUpdateDelegate(platform_ActiveComponentUpdateEvent); fxpaBaseForm = null; Application.ExitThread(); } }
protected virtual bool OnInitialize(FxpaBase platform) { return(true); }
protected bool OnInitialize(FxpaBase platform) { UpdateAvailableSourceSessions(); return(true); }