public static void CreateWindow(Window parent, IHOTASCollection deviceList, Action <EventHandler <AxisChangedEventArgs> > handler, Action <EventHandler <AxisChangedEventArgs> > callBackRemoveHandler) { if (_thisWindow != null) { _thisWindow.Show(); return; } _thisWindow = new InputGraphWindow(deviceList, handler, callBackRemoveHandler) { Owner = parent }; _thisWindow.Show(); }
private void ShowInputGraphWindow(ShowInputGraphWindowEvent eventMessage) { InputGraphWindow.CreateWindow(_mainWindow, eventMessage.DeviceList, eventMessage.AxisChangedHandler, eventMessage.CancelCallbackRemoveHandler); }
protected override void OnClosed(EventArgs e) { _dispatcherTimer.Stop(); _callBackRemoveHandler(AxisChangedHandler); _thisWindow = null; }