summaryrefslogtreecommitdiffstats
path: root/macosx/HBPreferencesController.m
diff options
context:
space:
mode:
authorritsuka <[email protected]>2013-10-25 18:21:54 +0000
committerritsuka <[email protected]>2013-10-25 18:21:54 +0000
commitef19311ee492b85995da5446d75e2cc0fdb40549 (patch)
treebd28a616c62f9a9c2eaa5d56f52795279ebf0adc /macosx/HBPreferencesController.m
parent32a56184a88817091950a94335dbf1036677eaf1 (diff)
MacGUI: Varius warnings fixes:
- NSUInteger and NSInteger instead of int (where the Cocoa 64bit api uses them). - Cast to int when needed because NSInteger on 64bit is defined as long. - NSURL instead of NSString when possible. - Replaced some deprecated methods/functions. - numberWithInteger instead of numberWithInt. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5854 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'macosx/HBPreferencesController.m')
-rw-r--r--macosx/HBPreferencesController.m9
1 files changed, 4 insertions, 5 deletions
diff --git a/macosx/HBPreferencesController.m b/macosx/HBPreferencesController.m
index 4e335ee69..544387dee 100644
--- a/macosx/HBPreferencesController.m
+++ b/macosx/HBPreferencesController.m
@@ -180,16 +180,15 @@
{
if( returnCode == NSOKButton )
{
- NSString *sendToAppPath = [[sheet filenames] objectAtIndex: 0];
- NSString *sendToAppDirectory = [sendToAppPath stringByDeletingLastPathComponent];
- [[NSUserDefaults standardUserDefaults] setObject:sendToAppDirectory forKey:@"LastSendToAppDirectory"];
+ NSURL *sendToAppURL = [[sheet URLs] objectAtIndex: 0];
+ NSURL *sendToAppDirectory = [sendToAppURL URLByDeletingLastPathComponent];
+ [[NSUserDefaults standardUserDefaults] setObject:[sendToAppDirectory path] forKey:@"LastSendToAppDirectory"];
[sheet orderOut: self];
NSString *sendToAppName;
- sendToAppName = [[sendToAppPath lastPathComponent] stringByDeletingPathExtension];
+ sendToAppName = [[sendToAppURL lastPathComponent] stringByDeletingPathExtension];
/* we set the name of the app to send to in the display field */
[fSendEncodeToAppField setStringValue:sendToAppName];
[[NSUserDefaults standardUserDefaults] setObject:[fSendEncodeToAppField stringValue] forKey:@"SendCompletedEncodeToApp"];
-
}
}