@@ -88,7 +88,6 @@ public FormMain(string[] args)
8888 InitializeComponent ( ) ;
8989
9090 Text = Properties . Settings . Default . ApplicationName ;
91- notifyIcon . Text = Properties . Settings . Default . ApplicationName + " (" + Properties . Settings . Default . ApplicationVersion + ")" ;
9291
9392 Log . Write ( "*** " + Properties . Settings . Default . ApplicationName + " (" + Properties . Settings . Default . ApplicationVersion + ") ***" ) ;
9493
@@ -3388,16 +3387,23 @@ private void RunTriggersOfConditionType(TriggerConditionType conditionType)
33883387 /// <param name="e"></param>
33893388 private void notifyIcon_MouseMove ( object sender , MouseEventArgs e )
33903389 {
3391- int remainingHours = ScreenCapture . TimeRemainingForNextScreenshot . Hours ;
3392- int remainingMinutes = ScreenCapture . TimeRemainingForNextScreenshot . Minutes ;
3393- int remainingSeconds = ScreenCapture . TimeRemainingForNextScreenshot . Seconds ;
3390+ if ( ScreenCapture . Running )
3391+ {
3392+ int remainingHours = ScreenCapture . TimeRemainingForNextScreenshot . Hours ;
3393+ int remainingMinutes = ScreenCapture . TimeRemainingForNextScreenshot . Minutes ;
3394+ int remainingSeconds = ScreenCapture . TimeRemainingForNextScreenshot . Seconds ;
33943395
3395- string remainingHoursStr = ( remainingHours > 0 ? remainingHours . ToString ( ) + " hour" + ( remainingHours > 1 ? "s" : string . Empty ) + ", " : string . Empty ) ;
3396- string remainingMinutesStr = ( remainingMinutes > 0 ? remainingMinutes . ToString ( ) + " minute" + ( remainingMinutes > 1 ? "s" : string . Empty ) + ", " : string . Empty ) ;
3396+ string remainingHoursStr = ( remainingHours > 0 ? remainingHours . ToString ( ) + " hour" + ( remainingHours > 1 ? "s" : string . Empty ) + ", " : string . Empty ) ;
3397+ string remainingMinutesStr = ( remainingMinutes > 0 ? remainingMinutes . ToString ( ) + " minute" + ( remainingMinutes > 1 ? "s" : string . Empty ) + ", " : string . Empty ) ;
33973398
3398- notifyIcon . Text = "Next screenshot in " +
3399- remainingHoursStr + remainingMinutesStr + remainingSeconds . ToString ( ) +
3400- " second" + ( remainingSeconds > 1 ? "s" : string . Empty ) + " at " + ScreenCapture . DateTimeNextScreenshot . ToShortTimeString ( ) ;
3399+ notifyIcon . Text = "Next screenshot in " +
3400+ remainingHoursStr + remainingMinutesStr + remainingSeconds . ToString ( ) +
3401+ " second" + ( remainingSeconds > 1 ? "s" : string . Empty ) + " at " + ScreenCapture . DateTimeNextScreenshot . ToLongTimeString ( ) ;
3402+ }
3403+ else
3404+ {
3405+ notifyIcon . Text = Properties . Settings . Default . ApplicationName + " (" + Properties . Settings . Default . ApplicationVersion + ")" ;
3406+ }
34013407 }
34023408 }
34033409}
0 commit comments