diff options
author | handbrake <[email protected]> | 2006-01-14 13:11:35 +0000 |
---|---|---|
committer | handbrake <[email protected]> | 2006-01-14 13:11:35 +0000 |
commit | 4beb6a8b483c9d84677b21cc271ce315f136335c (patch) | |
tree | e0ac0d4d1748ddde2ccc9a3310c3168474f266d9 /macosx/Controller.mm | |
parent | 5bfcc1c3cf9baed140c62c37a13c5087bbd3d5cf (diff) |
HandBrake 0.5.2
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@9 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'macosx/Controller.mm')
-rw-r--r-- | macosx/Controller.mm | 32 |
1 files changed, 22 insertions, 10 deletions
diff --git a/macosx/Controller.mm b/macosx/Controller.mm index 0b452bf91..ea5a2c161 100644 --- a/macosx/Controller.mm +++ b/macosx/Controller.mm @@ -1,4 +1,4 @@ -/* $Id: Controller.mm,v 1.9 2003/11/09 22:06:15 titer Exp $ +/* $Id: Controller.mm,v 1.10 2003/11/13 01:40:44 titer Exp $ This file is part of the HandBrake source code. Homepage: <http://handbrake.m0k.org/>. @@ -327,12 +327,24 @@ - (IBAction) Cancel: (id) sender { - HBStopRip( fHandle ); + NSBeginCriticalAlertSheet( @"Cancel - Are you sure?", + @"Nooo, keep going!", @"Yep, stop it", nil, fWindow, self, + @selector( _Cancel:returnCode:contextInfo: ), + nil, nil, @"Encoding won't be recoverable." ); } -- (IBAction) Suspend: (id) sender +- (void) _Cancel: (NSWindow *) sheet + returnCode: (int) returnCode contextInfo: (void *) contextInfo +{ + if( returnCode == NSAlertAlternateReturn ) + { + HBStopRip( fHandle ); + } +} + +- (IBAction) Pause: (id) sender { - if( [[fSuspendButton title] compare: @"Resume" ] == NSOrderedSame ) + if( [[fPauseButton title] compare: @"Resume" ] == NSOrderedSame ) { [self Resume: self]; return; @@ -498,7 +510,7 @@ /* Show the new GUI */ [fWindow setContentView: fRipView ]; - [fSuspendButton setEnabled: NO]; + [fPauseButton setEnabled: NO]; [fTitlePopUp removeAllItems]; HBTitle * title; @@ -537,8 +549,8 @@ [fFileFormatPopUp setEnabled: NO]; [fFileField setEnabled: NO]; [fFileBrowseButton setEnabled: NO]; - [fSuspendButton setEnabled: YES]; - [fSuspendButton setTitle: @"Suspend"]; + [fPauseButton setEnabled: YES]; + [fPauseButton setTitle: @"Pause"]; [fRipButton setTitle: @"Cancel"]; } @@ -588,7 +600,7 @@ [fRipProgress setDoubleValue: 100 * status.position]; - [fSuspendButton setTitle: @"Resume"]; + [fPauseButton setTitle: @"Resume"]; break; } @@ -681,8 +693,8 @@ [fFileFormatPopUp setEnabled: YES]; [fFileField setEnabled: YES]; [fFileBrowseButton setEnabled: YES]; - [fSuspendButton setEnabled: NO]; - [fSuspendButton setTitle: @"Suspend"]; + [fPauseButton setEnabled: NO]; + [fPauseButton setTitle: @"Pause"]; [fRipButton setTitle: @"Rip"]; [self VideoMatrixChanged: self]; |