vlc | branch: master | David Fuhrmann <david.fuhrm...@googlemail.com> | Sat Dec 29 17:33:08 2012 +0100| [7e96734bbd094e8856d354b9e1225838f6af9adc] | committer: David Fuhrmann
macosx: add mouse scroll support for fullscreen time slider > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7e96734bbd094e8856d354b9e1225838f6af9adc --- modules/gui/macosx/fspanel.h | 3 +++ modules/gui/macosx/fspanel.m | 8 ++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/modules/gui/macosx/fspanel.h b/modules/gui/macosx/fspanel.h index d51198b..a997b07 100644 --- a/modules/gui/macosx/fspanel.h +++ b/modules/gui/macosx/fspanel.h @@ -76,12 +76,15 @@ - (void)setVoutWasUpdated: (VLCWindow *)o_window; @end +@class VLCProgressView; + @interface VLCFSPanelView : NSView { NSColor *fillColor; NSButton *o_prev, *o_next, *o_bwd, *o_fwd, *o_play, *o_fullscreen; NSTextField *o_streamTitle_txt, *o_streamPosition_txt; NSSlider *o_fs_timeSlider, *o_fs_volumeSlider; + VLCProgressView *o_progress_view; NSImage *o_background_img, *o_vol_sld_img, *o_vol_mute_img, *o_vol_max_img, *o_time_sld_img; NSTimeInterval last_fwd_event; NSTimeInterval last_bwd_event; diff --git a/modules/gui/macosx/fspanel.m b/modules/gui/macosx/fspanel.m index f8f5f28..d941fc3 100644 --- a/modules/gui/macosx/fspanel.m +++ b/modules/gui/macosx/fspanel.m @@ -417,11 +417,14 @@ [o_bwd setContinuous:YES]; /* time slider */ - s_rc = [self frame]; + // (surrounding progress view for swipe behaviour) s_rc.origin.x = 15; s_rc.origin.y = 45; s_rc.size.width = 518; s_rc.size.height = 13; + o_progress_view = [[VLCProgressView alloc] initWithFrame: s_rc]; + s_rc.origin.x = 0; + s_rc.origin.y = 0; o_fs_timeSlider = [[VLCFSTimeSlider alloc] initWithFrame: s_rc]; [o_fs_timeSlider setMinValue:0]; [o_fs_timeSlider setMaxValue:10000]; @@ -431,7 +434,8 @@ [o_fs_timeSlider setAction: @selector(fsTimeSliderUpdate:)]; [[o_fs_volumeSlider cell] accessibilitySetOverrideValue:_NS("Position") forAttribute:NSAccessibilityTitleAttribute]; [[o_fs_timeSlider cell] accessibilitySetOverrideValue:_NS("Click and move the mouse while keeping the button pressed to use this slider to change current playback position.") forAttribute:NSAccessibilityDescriptionAttribute]; - [self addSubview: o_fs_timeSlider]; + [self addSubview: o_progress_view]; + [o_progress_view addSubview: o_fs_timeSlider]; /* volume slider */ s_rc = [self frame]; _______________________________________________ vlc-commits mailing list vlc-commits@videolan.org http://mailman.videolan.org/listinfo/vlc-commits