예제 #1
0
        private void Form1_FormClosed(object sender, FormClosedEventArgs e)
        {
            FileAssociationSingleInstance.UnRegisterAsSingleInstance();
            if (controlbar != null)
            {
                controlbar.SaveSettings();
            }

            if (model_loading_manager != null)
            {
                model_loading_manager.OnShutdown();
            }

            if (settingsManager != null)
            {
                settingsManager.OnShutdown();
            }

            if (spooler_connection == null)
            {
                return;
            }

            spooler_connection.OnShutdown();
        }
예제 #2
0
        public static void ShowExceptionForm(Exception e, string extra_info)
        {
            if (ExceptionForm.form1 != null)
            {
                ExceptionForm.form1.StopTimers();
            }

            FileAssociationSingleInstance.UnRegisterAsSingleInstance();
            var num = (int)new ExceptionForm()
            {
                the_exception = e, extra_info = extra_info
            }.ShowDialog();

            Application.Exit();
        }