示例#1
0
 private void _view_ProcessInfoControlHandleDestroyed(object sender, EventArgs e)
 {
     try
     {
         if (_processInfoService != null)
         {
             _processInfoService.Dispose();
         }
     }
     catch (Exception ex)
     {
         _loggerFactory.ErrorLogged(ex);
     }
 }
示例#2
0
        private void _view_MainFormFormClosed(object sender, EventArgs e)
        {
            try
            {
                _loggerFactory.CloseProgramLogged();

                if (_processInfoService != null)
                {
                    _processInfoService.Dispose();
                }

                if (_timeManager != null)
                {
                    _timeManager.Stop();
                    _timeManager.Dispose();
                }
            }
            catch (Exception ex)
            {
                _loggerFactory.ErrorLogged(ex);
            }
        }