Пример #1
0
Файл: App.cs Проект: wpmyj/c3
        /// <summary>
        ///
        /// </summary>
        /// <param name="exitCode"></param>
        virtual public void Exit(int exitCode)
        {
            this._isSuredToQuit = true;

            //OnApplicationExit();
            DisposeMainFormOrNot();
            NotifyIconManager.Stop();
            //Environment.Exit(exitCode);
            this.MainForm.Close();
        }
Пример #2
0
Файл: App.cs Проект: wpmyj/c3
        /// <summary>
        ///
        /// </summary>
        virtual public void Run()
        {
            if (IsSingleApplication && Xdgk.Common.Diagnostics.HasPreInstance())
            {
                ShowRunningMessage();
                return;
            }
            else
            {
                if (NotifyIconManager.EnabledNotifyIcon)
                {
                    NotifyIconManager.Start();
                    this.MainForm.FormClosing += new FormClosingEventHandler(MainForm_FormClosing);
                }

                Application.Run(MainForm);
            }
        }