Browse Source

macosx: fixed compilation for llvm-gcc-4.2

pull/3/head
Felix Paul Kühne 14 years ago
committed by Felix Paul Kühne
parent
commit
64de31cb58
  1. 4
      modules/gui/macosx/StringUtility.m
  2. 15
      modules/gui/macosx/VLCVoutWindowController.m

4
modules/gui/macosx/StringUtility.m

@ -280,7 +280,9 @@ unsigned int CocoaKeyToVLC(unichar i_key)
theString = [theString stringByReplacingOccurrencesOfString:@"Ctrl" withString:@""];
}
#ifdef __clang__
#pragma GCC diagnostic ignored "-Wformat"
#endif
if ([theString length] > 1) {
if ([theString rangeOfString:@"Up"].location != NSNotFound)
return [NSString stringWithFormat:@"%C", NSUpArrowFunctionKey];
@ -336,7 +338,9 @@ unsigned int CocoaKeyToVLC(unichar i_key)
return [NSString stringWithFormat:@"%C", NSF1FunctionKey];
/* note that we don't support esc here, since it is reserved for leaving fullscreen */
}
#ifdef __clang__
#pragma GCC diagnostic warning "-Wformat"
#endif
return theString;
}

15
modules/gui/macosx/VLCVoutWindowController.m

@ -66,10 +66,12 @@
- (void)updateWindowsControlsBarWithSelector:(SEL)aSel
{
[o_vout_dict enumerateKeysAndObjectsUsingBlock:^(id key, VLCVideoWindowCommon *o_window, BOOL *stop) {
id o_controlsBar = [o_window controlsBar];
if (o_controlsBar)
[o_controlsBar performSelector:aSel];
[o_vout_dict enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL *stop) {
if ([obj respondsToSelector:@selector(controlsBar)]) {
id o_controlsBar = [obj controlsBar];
if (o_controlsBar)
[o_controlsBar performSelector:aSel];
}
}];
}
@ -86,8 +88,9 @@
- (void)updateWindowsUsingBlock:(void (^)(VLCVideoWindowCommon *o_window))windowUpdater
{
[o_vout_dict enumerateKeysAndObjectsUsingBlock:^(id key, VLCVideoWindowCommon *o_window, BOOL *stop) {
windowUpdater(o_window);
[o_vout_dict enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL *stop) {
if ([obj isKindOfClass: [NSWindow class]])
windowUpdater(obj);
}];
}

Loading…
Cancel
Save