From: Felix Paul Kühne Date: Sat, 23 Aug 2008 21:37:21 +0000 (+0200) Subject: macosx: compilation fix for the 10.4u SDK and removal of a hack X-Git-Tag: 0.9.0~59 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=20e0e10972176a97a348f56b51e3b998715bff3e;p=vlc macosx: compilation fix for the 10.4u SDK and removal of a hack Note that all NS*Integer types were introduced on 10.5 only. They can tollfree bridged with the respective plain ints. They are undocumented anyway... --- diff --git a/modules/gui/macosx/embeddedwindow.h b/modules/gui/macosx/embeddedwindow.h index f451b51697..ead8618f72 100644 --- a/modules/gui/macosx/embeddedwindow.h +++ b/modules/gui/macosx/embeddedwindow.h @@ -53,7 +53,7 @@ BOOL b_window_is_invisible; NSSize videoRatio; - NSInteger originalLevel; + int originalLevel; } - (void)controlTintChanged; diff --git a/modules/gui/macosx/intf.h b/modules/gui/macosx/intf.h index ded1405908..ed999e22fd 100644 --- a/modules/gui/macosx/intf.h +++ b/modules/gui/macosx/intf.h @@ -37,12 +37,6 @@ #include -/* this was introduced in Darwin 9. We need to declare it to prevent both - * compilation warnings and errors */ -#ifndef NSInteger -#define NSInteger int -#endif - /***************************************************************************** * Local prototypes. *****************************************************************************/ diff --git a/modules/gui/macosx/intf.m b/modules/gui/macosx/intf.m index 7274687d0e..256f6a2331 100644 --- a/modules/gui/macosx/intf.m +++ b/modules/gui/macosx/intf.m @@ -2124,10 +2124,10 @@ end: NSDirectoryEnumerator *direnum = [[NSFileManager defaultManager] enumeratorAtPath:crashReporter]; NSString *fname; NSString * latestLog = nil; - NSInteger year = !previouslySeen ? [[NSUserDefaults standardUserDefaults] integerForKey:@"LatestCrashReportYear"] : 0; - NSInteger month = !previouslySeen ? [[NSUserDefaults standardUserDefaults] integerForKey:@"LatestCrashReportMonth"]: 0; - NSInteger day = !previouslySeen ? [[NSUserDefaults standardUserDefaults] integerForKey:@"LatestCrashReportDay"] : 0; - NSInteger hours = !previouslySeen ? [[NSUserDefaults standardUserDefaults] integerForKey:@"LatestCrashReportHours"]: 0; + int year = !previouslySeen ? [[NSUserDefaults standardUserDefaults] integerForKey:@"LatestCrashReportYear"] : 0; + int month = !previouslySeen ? [[NSUserDefaults standardUserDefaults] integerForKey:@"LatestCrashReportMonth"]: 0; + int day = !previouslySeen ? [[NSUserDefaults standardUserDefaults] integerForKey:@"LatestCrashReportDay"] : 0; + int hours = !previouslySeen ? [[NSUserDefaults standardUserDefaults] integerForKey:@"LatestCrashReportHours"]: 0; while (fname = [direnum nextObject]) { diff --git a/modules/gui/macosx/playlist.m b/modules/gui/macosx/playlist.m index 4ae969649d..5dad4232ce 100644 --- a/modules/gui/macosx/playlist.m +++ b/modules/gui/macosx/playlist.m @@ -1221,7 +1221,7 @@ pt = [o_outline_view convertPoint: [o_event locationInWindow] fromView: nil]; - NSInteger row = [o_outline_view rowAtPoint:pt]; + int row = [o_outline_view rowAtPoint:pt]; if( row != -1 ) [o_outline_view selectRowIndexes:[NSIndexSet indexSetWithIndex:row] byExtendingSelection:NO]; diff --git a/modules/gui/macosx/simple_prefs.h b/modules/gui/macosx/simple_prefs.h index 20c091886c..60539e07b6 100644 --- a/modules/gui/macosx/simple_prefs.h +++ b/modules/gui/macosx/simple_prefs.h @@ -202,8 +202,8 @@ /* hotkeys */ - (IBAction)hotkeySettingChanged:(id)sender; - (void)showHotkeySettings; -- (NSInteger)numberOfRowsInTableView:(NSTableView *)aTableView; -- (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(NSInteger)rowIndex; +- (int)numberOfRowsInTableView:(NSTableView *)aTableView; +- (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(int)rowIndex; - (BOOL)changeHotkeyTo: (int)i_theNewKey; @end diff --git a/modules/gui/macosx/simple_prefs.m b/modules/gui/macosx/simple_prefs.m index d6f1a6e0a7..5052f2413d 100644 --- a/modules/gui/macosx/simple_prefs.m +++ b/modules/gui/macosx/simple_prefs.m @@ -1193,12 +1193,12 @@ static inline void save_module_list( intf_thread_t * p_intf, id object, const ch [self showSettingsForCategory: o_hotkeys_view]; } -- (NSInteger)numberOfRowsInTableView:(NSTableView *)aTableView +- (int)numberOfRowsInTableView:(NSTableView *)aTableView { return [o_hotkeySettings count]; } -- (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(NSInteger)rowIndex +- (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(int)rowIndex { if( [[aTableColumn identifier] isEqualToString: @"action"] ) return [o_hotkeyDescriptions objectAtIndex: rowIndex];