]> git.sesse.net Git - vlc/blobdiff - modules/gui/macosx/vout.m
Fix utf8_readdir usage
[vlc] / modules / gui / macosx / vout.m
index f4b0f4dc754f0b1bec1b0d1cd90752edfa81b8d9..78e04a5daabafcb91b840f3bcab22b257d726d63 100644 (file)
@@ -439,6 +439,12 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
     return o_window;
 }
 
+- (void)scrollWheel:(NSEvent *)theEvent
+{
+    VLCControls * o_controls = (VLCControls *)[[NSApp delegate] getControls];
+    [o_controls scrollWheel: theEvent];
+}
+
 - (void)keyDown:(NSEvent *)o_event
 {
     unichar key = 0;
@@ -751,13 +757,13 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
 
 - (void)enterFullscreen
 {
-    [[o_view class] resetVout: p_vout];
+    [[o_view class] performSelectorOnMainThread:@selector(resetVout:) withObject:[NSValue valueWithPointer:p_vout] waitUntilDone:YES];
     [[[[VLCMain sharedInstance] getControls] getFSPanel] setActive: nil];
 }
 
 - (void)leaveFullscreen
 {
-    [[o_view class] resetVout: p_vout];
+    [[o_view class] performSelectorOnMainThread:@selector(resetVout:) withObject:[NSValue valueWithPointer:p_vout] waitUntilDone:YES];
     [[[[VLCMain sharedInstance] getControls] getFSPanel] setNonActive: nil];
 }
 
@@ -939,6 +945,8 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
 
         [self scaleWindowWithFactor: 1.0 animate: [o_window isVisible] && (![o_window isFullscreen])];
 
+        [o_window setAspectRatio:NSMakeSize([o_window frame].size.width, [o_window frame].size.height)];
+
         /* Make sure our window is visible, if we are not in fullscreen */
         if (![o_window isFullscreen])
             [o_window makeKeyAndOrderFront: self];