vlc | branch: master | Felix Paul Kühne <[email protected]> | Mon Mar 25 17:10:48 2019 +0100| [d42c089e61f1eec76cb722ce9b1a7188a8e0f2c9] | committer: Felix Paul Kühne
macosx: replace previous A→B loop implementation > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=d42c089e61f1eec76cb722ce9b1a7188a8e0f2c9 --- .../macosx/coreinteraction/VLCCoreInteraction.h | 3 -- .../macosx/coreinteraction/VLCCoreInteraction.m | 43 ---------------------- .../gui/macosx/coreinteraction/VLCInputManager.m | 1 - modules/gui/macosx/menus/VLCMainMenu.m | 3 +- .../gui/macosx/windows/mainwindow/VLCMainWindow.m | 2 - 5 files changed, 1 insertion(+), 51 deletions(-) diff --git a/modules/gui/macosx/coreinteraction/VLCCoreInteraction.h b/modules/gui/macosx/coreinteraction/VLCCoreInteraction.h index 5ab6bb70bc..6d96e52ff7 100644 --- a/modules/gui/macosx/coreinteraction/VLCCoreInteraction.h +++ b/modules/gui/macosx/coreinteraction/VLCCoreInteraction.h @@ -60,9 +60,6 @@ - (void)repeatAll; - (void)repeatOff; - (void)shuffle; -- (void)setAtoB; -- (void)resetAtoB; -- (void)updateAtoB; - (void)volumeUp; - (void)volumeDown; diff --git a/modules/gui/macosx/coreinteraction/VLCCoreInteraction.m b/modules/gui/macosx/coreinteraction/VLCCoreInteraction.m index 3805742f18..34c0ee10c6 100644 --- a/modules/gui/macosx/coreinteraction/VLCCoreInteraction.m +++ b/modules/gui/macosx/coreinteraction/VLCCoreInteraction.m @@ -53,7 +53,6 @@ static int BossCallback(vlc_object_t *p_this, const char *psz_var, @interface VLCCoreInteraction () { float f_currentPlaybackRate; - vlc_tick_t timeA, timeB; float f_maxVolume; @@ -412,48 +411,6 @@ static int BossCallback(vlc_object_t *p_this, const char *psz_var, [_playerController displayOSDMessage:_NS("Repeat Off")]; } -- (void)setAtoB -{ - if (!timeA) { - input_thread_t * p_input = pl_CurrentInput(getIntf()); - if (p_input) { - msg_Dbg(getIntf(), "Setting A value"); - - timeA = var_GetInteger(p_input, "time"); - input_Release(p_input); - } - } else if (!timeB) { - input_thread_t * p_input = pl_CurrentInput(getIntf()); - if (p_input) { - msg_Dbg(getIntf(), "Setting B value"); - - timeB = var_GetInteger(p_input, "time"); - input_Release(p_input); - } - } else - [self resetAtoB]; -} - -- (void)resetAtoB -{ - msg_Dbg(getIntf(), "Resetting A to B values"); - timeA = 0; - timeB = 0; -} - -- (void)updateAtoB -{ - if (timeB) { - input_thread_t * p_input = pl_CurrentInput(getIntf()); - if (p_input) { - vlc_tick_t currentTime = var_GetInteger(p_input, "time"); - if ( currentTime >= timeB || currentTime < timeA) - var_SetInteger(p_input, "time", timeA); - input_Release(p_input); - } - } -} - - (void)jumpToTime:(vlc_tick_t)time { input_thread_t * p_input = pl_CurrentInput(getIntf()); diff --git a/modules/gui/macosx/coreinteraction/VLCInputManager.m b/modules/gui/macosx/coreinteraction/VLCInputManager.m index 4928f6d955..5336633011 100644 --- a/modules/gui/macosx/coreinteraction/VLCInputManager.m +++ b/modules/gui/macosx/coreinteraction/VLCInputManager.m @@ -270,7 +270,6 @@ static int InputEvent(vlc_object_t *p_this, const char *psz_var, - (void)updateMainMenu { [[o_main mainMenu] setupMenus]; - [[VLCCoreInteraction sharedInstance] resetAtoB]; } - (BOOL)hasInput diff --git a/modules/gui/macosx/menus/VLCMainMenu.m b/modules/gui/macosx/menus/VLCMainMenu.m index a79c99214a..90aab5aa67 100644 --- a/modules/gui/macosx/menus/VLCMainMenu.m +++ b/modules/gui/macosx/menus/VLCMainMenu.m @@ -854,8 +854,7 @@ - (IBAction)toggleAtoBloop:(id)sender { - // re-write the following using VLCPlayerController - [[VLCCoreInteraction sharedInstance] setAtoB]; + [_playerController setABLoop]; } - (IBAction)goToSpecificTime:(id)sender diff --git a/modules/gui/macosx/windows/mainwindow/VLCMainWindow.m b/modules/gui/macosx/windows/mainwindow/VLCMainWindow.m index 52c38cc741..8a79b12d2f 100644 --- a/modules/gui/macosx/windows/mainwindow/VLCMainWindow.m +++ b/modules/gui/macosx/windows/mainwindow/VLCMainWindow.m @@ -571,8 +571,6 @@ static const float f_min_window_height = 307.; - (void)updateTimeSlider { [self.fspanel updatePositionAndTime]; - - [[VLCCoreInteraction sharedInstance] updateAtoB]; } - (void)updateName _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
