Index: macosx/Controller.mm===================================================================--- macosx/Controller.mm (revision 758)+++ macosx/Controller.mm (working copy)@@ -1506,6 +1506,36 @@ [NSApp terminate: self]; }+- (void) RemindUserOfSleepOrShutdown+{+ if ([[[NSUserDefaults standardUserDefaults] stringForKey:@"AlertWhenDone"] isEqualToString: @"Put Computer To Sleep"])+ {+ /*Warn that computer will sleep after encoding*/+ int reminduser;+ id sender;+ NSBeep();+ reminduser = NSRunAlertPanel(@"The computer will sleep after encoding is done.",@"You have selected to sleep the computer after encoding. To turn off sleeping, go to the HandBrake preferences.", @"OK", @"Preferences?", nil);+ [NSApp requestUserAttention:NSCriticalRequest];+ if ( reminduser == NSAlertAlternateReturn ) + {+ [self showPreferencesWindow: sender];+ }+ } else if ([[[NSUserDefaults standardUserDefaults] stringForKey:@"AlertWhenDone"] isEqualToString: @"Shut Down Computer"])+ {+ /*Warn that computer will sleep after encoding*/+ int reminduser;+ id sender;+ NSBeep();+ reminduser = NSRunAlertPanel(@"The computer will shut down after encoding is done.",@"You have selected to shut down the computer after encoding. To turn off shut down, go to the HandBrake preferences.", @"OK", @"Preferences?", nil);+ [NSApp requestUserAttention:NSCriticalRequest];+ if ( reminduser == NSAlertAlternateReturn ) + {+ [self showPreferencesWindow: sender];+ }+ }+ return;+}+ - (void) _Rip { /* Let libhb do the job */@@ -1525,6 +1555,7 @@ frame.size.height += 44; frame.origin.y -= 44; [fWindow setFrame:frame display:YES animate:YES];+ [self RemindUserOfSleepOrShutdown]; } - (IBAction) Cancel: (id) sender