public void Stop()
        {
            lock (startStopSyncObj)
            {
                if (!Active)
                {
                    return;
                }

                listener?.Dispose();
                logger?.Flush();

                Active = false;
            }
        }
Exemple #2
0
        protected override void OnClosing(System.ComponentModel.CancelEventArgs e)
        {
            keyboardListener.Dispose();
            windowManagerThread.Abort();

            System.Windows.Application.Current.Shutdown();
        }
Exemple #3
0
 private void UnHookKeyboard()
 {
     if (_keyboardListener != null)
     {
         _keyboardListener.Dispose();
         _keyboardListener = null;
     }
 }
Exemple #4
0
 private void CloseDownEverything()
 {
     m_DrawWindow.Close();
     GetRidOfTrayIcon();
     if (m_KeyboardListener != null)
     {
         m_KeyboardListener.Dispose();
     }
 }
 private void StopHooks()
 {
     try
     {
         KListener.Dispose();
         MListener.Dispose();
     }
     catch (NullReferenceException) { }
 }
Exemple #6
0
        public override void Cleanup()
        {
            // Clean up if needed
#if !DEBUG
            keyboardListener.Dispose();
#endif
            MessengerInstance.Unregister <bool>(this, "ReopenMainWindow");
            MessengerInstance.Unregister <ChatMessage>(this, "SetChannel");

            base.Cleanup();
        }
Exemple #7
0
 public void Closing()
 {
     if (MusicManager != null)
     {
         MusicManager.CSCoreEngine.StopPlayback();
         MusicManager.SaveToSettings();
         MySettings.CurrentState.MainTabControlIndex = MainTabControlIndex;
         MySettings.Save();
         MusicManager.Dispose();
     }
     _keyboardListener?.Dispose();
 }
Exemple #8
0
        public static void Dispose()
        {
            System.Windows.Forms.Application.RemoveMessageFilter(keyBoardListener);

            foreach (string displayName in displayNames)
            {
                System.Windows.Forms.Application.RemoveMessageFilter(mouseListeners[displayName]);
            }

            keyBoardListener.Dispose();

            mouseListeners.Clear();
            currentMouseButtonStates.Clear();
            previousMouseButtonStates.Clear();
        }
Exemple #9
0
 public void Closing()
 {
     if (MusicManager != null)
     {
         MusicManager.CSCoreEngine.StopPlayback();
         MusicManager.SaveToSettings();
         MySettings.CurrentState.MainTabControlIndex = MainTabControlIndex;
         MySettings.Save();
         MusicManager.Dispose();
     }
     if (_keyboardListener != null)
     {
         _keyboardListener.Dispose();
     }
     if (Updater != null)
     {
         Updater.Dispose();
     }
     HurricaneSettings.Instance.Config.AppCommunicationManager.Stop();
 }
 internal void Stop()
 {
     _keyboardListener.KeyDown -= KbListener_KeyDown;
     _keyboardListener.KeyUp   -= KBListener_KeyUp;
     _keyboardListener.Dispose();
 }
Exemple #11
0
 public void OnWindowClosing(object sender, CancelEventArgs e)
 {
     KListener.Dispose();
 }
Exemple #12
0
 public void Dispose()
 {
     _keyboard.Dispose();
 }
Exemple #13
0
 public virtual void Dispose()
 {
     _changes.DisposeEverything();
     _keyboard?.Dispose();
 }
Exemple #14
0
 public void Dispose()
 {
     _keyboard.Dispose();
     MuiSystemAccent.SystemColorsChanged -= OnSystemColorsChanged;
 }
Exemple #15
0
 private void ApplicationExit(object sender, ExitEventArgs e)
 {
     _keyboardListener.Dispose();
 }
Exemple #16
0
 private void Application_Exit(object sender, ExitEventArgs e)
 {
     KListener.Dispose();
 }
Exemple #17
0
 public void Dispose()
 {
     keyListener.Dispose();
 }