示例#1
0
 private void NotifyIcon_MouseDoubleClick(object sender, System.Windows.Forms.MouseEventArgs e)
 {
     if (e.Button == System.Windows.Forms.MouseButtons.Left && !backgroundWorker.IsBusy)
     {
         //双击托盘图标进入或退出番茄时钟模式
         config.SaveOldOptions();
         config.options.General.IsTomatoMode = !config.options.General.IsTomatoMode;
         config.OnChanged();
     }
 }
示例#2
0
 public void Close()
 {
     workCount = 0;
     restartCount++;
     workTimer.Stop();
     restTimer.Stop();
     config.SaveOldOptions();
     config.options.General.IsTomatoMode = false;
     config.OnChanged();
     SaveData();
 }