public void Dispose() { FilesSavingQueue.FlushSynchroniously(); if (calibration_window != null) { calibration_window.Close(); calibration_window = null; } }
private static void Shutdown(object sender, EventArgs e) { input_manager.Stop(); eye_tracking_mouse.StopControlling(); Helpers.tray_icon.Visible = false; FilesSavingQueue.FlushSynchroniously(); System.Windows.Application.Current.Shutdown(); }
private static void Shutdown(object sender, EventArgs e) { if (MessageBox.Show( "This will prevent you from controlling mouse with your eyes.\nSure you want to quit?", Helpers.application_name, MessageBoxButton.YesNo) == MessageBoxResult.Yes) { input_manager.Stop(); eye_tracking_mouse.StopControlling(); Helpers.tray_icon.Visible = false; FilesSavingQueue.FlushSynchroniously(); System.Windows.Application.Current.Shutdown(); } }