]> git.sesse.net Git - vlc/commitdiff
Redirected "zoom" on "scale" (vout_thread_t).
authorLaurent Aimar <fenrir@videolan.org>
Tue, 26 Jan 2010 22:34:02 +0000 (23:34 +0100)
committerLaurent Aimar <fenrir@videolan.org>
Tue, 26 Jan 2010 22:34:02 +0000 (23:34 +0100)
It fixes zoom settings at the core level (partially close #3245).
"zoom" cannot be removed as it provides a list of choices while "scale" is
a free value. The names aren't great, but that can wait.

src/video_output/vout_intf.c

index 33364817694459bdb54585a2e1135cbc58bfcbb1..0856b48b2850c1ba3178128007705b1876584dff 100644 (file)
@@ -699,13 +699,7 @@ static void InitWindowSize( vout_thread_t *p_vout, unsigned *pi_width,
 static int ZoomCallback( vlc_object_t *p_this, char const *psz_cmd,
                          vlc_value_t oldval, vlc_value_t newval, void *p_data )
 {
-    vout_thread_t *p_vout = (vout_thread_t *)p_this;
-    (void)psz_cmd; (void)oldval; (void)newval; (void)p_data;
-    InitWindowSize( p_vout, &p_vout->i_window_width,
-                    &p_vout->i_window_height );
-    vout_Control( p_vout, VOUT_SET_SIZE, p_vout->i_window_width,
-                  p_vout->i_window_height );
-    return VLC_SUCCESS;
+    return var_SetFloat( p_this, "scale", newval.f_float );
 }
 
 static int CropCallback( vlc_object_t *p_this, char const *psz_cmd,