Commit a26d9914 authored by Felix Paul Kühne's avatar Felix Paul Kühne

gui/macosx: fixed a few logic errors introduced in [24189] (refs #1427)

parent 92759c9e
......@@ -29,6 +29,7 @@
#import "controls.h"
#import "vout.h"
#import "fspanel.h"
#import "misc.h"
#define KEEP_VISIBLE_AFTER_ACTION 4 /* time in half-sec until this panel will hide again after an user's action */
......
......@@ -166,7 +166,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
int i_device;
NSAutoreleasePool *o_pool = [[NSAutoreleasePool alloc] init];
NSArray *o_screens = [NSScreen screens];
NSArray *o_fullscreen_screen = nil;
NSScreen *o_fullscreen_screen = nil;
p_vout = vout;
o_view = view;
......@@ -187,7 +187,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
i_device = var_GetInteger( p_real_vout->p_vlc, "video-device" );
}
o_fullscreen_screen = [NSScreen screenWithDisplayID:i_device];
o_fullscreen_screen = [NSScreen screenWithDisplayID: (CGDirectDisplayID)i_device];
if( !o_fullscreen_screen )
o_fullscreen_screen = [[self window] screen];
......@@ -222,7 +222,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
(int)s_rect.size.width, (int)s_rect.size.height );
text.psz_string = psz_temp;
val2.i_int = [o_screen displayID];
val2.i_int = (int)[o_screen displayID];
var_Change( p_real_vout, "video-device",
VLC_VAR_ADDCHOICE, &val2, &text );
if( [o_screen isScreen:o_fullscreen_screen] )
......@@ -1014,7 +1014,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
/* Find out on which screen to open the window */
o_screen = [NSScreen screenWithDisplayID: (CGDirectDisplayID)i_device];
if( !o_screen )
o_screen = [[self window] screen];
o_screen = [self screen];
if( [o_screen isMainScreen] )
b_menubar_screen = VLC_TRUE;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment