vlc | branch: master | Felix Paul Kühne <[email protected]> | Mon Mar 11 01:08:18 2019 +0100| [900cb6ee6f3ba7abe321dabe30a7fe6d9197e1a6] | committer: Felix Paul Kühne
macosx: don't import the legacy playlist globally Import it where needed only to identify those areas > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=900cb6ee6f3ba7abe321dabe30a7fe6d9197e1a6 --- modules/gui/macosx/coreinteraction/VLCCoreInteraction.m | 3 +++ modules/gui/macosx/coreinteraction/VLCInputManager.m | 1 + modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m | 2 ++ modules/gui/macosx/main/VLCMain+OldPrefs.m | 8 -------- modules/gui/macosx/main/VLCMain.h | 4 ---- modules/gui/macosx/main/VLCMain.m | 2 ++ modules/gui/macosx/menus/VLCMainMenu.m | 2 ++ modules/gui/macosx/menus/VLCStatusBarIcon.m | 1 - modules/gui/macosx/panels/VLCAudioEffectsWindowController.m | 3 +++ modules/gui/macosx/panels/VLCBookmarksWindowController.m | 1 + modules/gui/macosx/panels/VLCInformationWindowController.m | 3 +-- .../gui/macosx/panels/VLCTrackSynchronizationWindowController.m | 2 ++ modules/gui/macosx/panels/VLCVideoEffectsWindowController.m | 3 +++ .../windows/convertandsave/VLCConvertAndSaveWindowController.m | 1 + modules/gui/macosx/windows/mainwindow/VLCControlsBarCommon.m | 2 ++ modules/gui/macosx/windows/mainwindow/VLCMainWindowControlsBar.m | 1 + modules/gui/macosx/windows/video/VLCFSPanelController.m | 1 + modules/gui/macosx/windows/video/VLCVideoOutputProvider.m | 1 + modules/gui/macosx/windows/video/VLCVideoWindowCommon.m | 3 +++ modules/gui/macosx/windows/video/VLCVoutView.m | 2 ++ modules/gui/macosx/windows/video/VLCWindow.m | 1 + 21 files changed, 32 insertions(+), 15 deletions(-) diff --git a/modules/gui/macosx/coreinteraction/VLCCoreInteraction.m b/modules/gui/macosx/coreinteraction/VLCCoreInteraction.m index 05e0f3e918..57ba42b16c 100644 --- a/modules/gui/macosx/coreinteraction/VLCCoreInteraction.m +++ b/modules/gui/macosx/coreinteraction/VLCCoreInteraction.m @@ -28,6 +28,8 @@ #import <vlc_plugin.h> #import <vlc_actions.h> +#import <vlc_playlist_legacy.h> + #import "main/VLCMain.h" #import "coreinteraction/VLCClickerManager.h" #import "playlist/VLCPlaylistController.h" @@ -35,6 +37,7 @@ #import "playlist/VLCPlaylistModel.h" #import "windows/VLCOpenWindowController.h" +#import "extensions/helpers.h" static int BossCallback(vlc_object_t *p_this, const char *psz_var, vlc_value_t oldval, vlc_value_t new_val, void *param) diff --git a/modules/gui/macosx/coreinteraction/VLCInputManager.m b/modules/gui/macosx/coreinteraction/VLCInputManager.m index b060ad0e3e..dcce15adb6 100644 --- a/modules/gui/macosx/coreinteraction/VLCInputManager.m +++ b/modules/gui/macosx/coreinteraction/VLCInputManager.m @@ -21,6 +21,7 @@ #import "VLCInputManager.h" #include <vlc_url.h> +#import <vlc_playlist_legacy.h> #import "coreinteraction/VLCCoreInteraction.h" #import "main/CompatibilityFixes.h" diff --git a/modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m b/modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m index f33b496514..3ddbf4a08a 100644 --- a/modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m +++ b/modules/gui/macosx/coreinteraction/VLCVideoFilterHelper.m @@ -24,8 +24,10 @@ #import <vlc_modules.h> #import <vlc_charset.h> +#import <vlc_playlist_legacy.h> #import "main/VLCMain.h" +#import "extensions/helpers.h" @implementation VLCVideoFilterHelper diff --git a/modules/gui/macosx/main/VLCMain+OldPrefs.m b/modules/gui/macosx/main/VLCMain+OldPrefs.m index 25a17cde0d..9066310d13 100644 --- a/modules/gui/macosx/main/VLCMain+OldPrefs.m +++ b/modules/gui/macosx/main/VLCMain+OldPrefs.m @@ -94,18 +94,10 @@ static const int kCurrentPreferencesVersion = 4; // In VLC 2.2.x, config for filters was fully controlled by audio and video effects panel. // In VLC 3.0, this is no longer the case and VLCs config is not touched anymore. Therefore, // disable filter in VLCs config in this transition. - playlist_t *p_playlist = pl_Get(getIntf()); - var_SetString(p_playlist, "audio-filter", ""); - var_SetString(p_playlist, "video-filter", ""); config_PutPsz("audio-filter", ""); config_PutPsz("video-filter", ""); config_SaveConfigFile(getIntf()); - - // This migration only has effect rarely, therefore only restart then - if (!hasUpdated) - return; - } else { NSArray *libraries = NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, NSUserDomainMask, YES); diff --git a/modules/gui/macosx/main/VLCMain.h b/modules/gui/macosx/main/VLCMain.h index c705c4532a..966485776e 100644 --- a/modules/gui/macosx/main/VLCMain.h +++ b/modules/gui/macosx/main/VLCMain.h @@ -31,7 +31,6 @@ #import <vlc_common.h> #import <vlc_interface.h> -#import <vlc_playlist_legacy.h> #import <vlc_vout.h> #import <vlc_aout.h> #import <vlc_input.h> @@ -50,9 +49,6 @@ intf_thread_t *getIntf(void); -// TODO fix include order -#import "extensions/helpers.h" - static NSString * VLCInputChangedNotification = @"VLCInputChangedNotification"; static NSString * VLCConfigurationChangedNotification = @"VLCConfigurationChangedNotification"; static NSString * VLCMediaKeySupportSettingChangedNotification = @"VLCMediaKeySupportSettingChangedNotification"; diff --git a/modules/gui/macosx/main/VLCMain.m b/modules/gui/macosx/main/VLCMain.m index ccc34f2f65..c43e62ff87 100644 --- a/modules/gui/macosx/main/VLCMain.m +++ b/modules/gui/macosx/main/VLCMain.m @@ -41,6 +41,7 @@ #include <vlc_dialog.h> #include <vlc_url.h> #include <vlc_variables.h> +#import <vlc_playlist_legacy.h> #import "coreinteraction/VLCCoreInteraction.h" #import "coreinteraction/VLCInputManager.h" @@ -73,6 +74,7 @@ #import "windows/VLCOpenInputMetadata.h" #import "windows/video/VLCVoutView.h" +#import "extensions/helpers.h" #ifdef HAVE_SPARKLE #import <Sparkle/Sparkle.h> /* we're the update delegate */ diff --git a/modules/gui/macosx/menus/VLCMainMenu.m b/modules/gui/macosx/menus/VLCMainMenu.m index 648a2f249b..f69d92ea81 100644 --- a/modules/gui/macosx/menus/VLCMainMenu.m +++ b/modules/gui/macosx/menus/VLCMainMenu.m @@ -58,6 +58,8 @@ #import "windows/logging/VLCLogWindowController.h" #import "windows/addons/VLCAddonsWindowController.h" +#import "extensions/helpers.h" + #ifdef HAVE_SPARKLE #import <Sparkle/Sparkle.h> #endif diff --git a/modules/gui/macosx/menus/VLCStatusBarIcon.m b/modules/gui/macosx/menus/VLCStatusBarIcon.m index 17eac4c612..52f537db72 100644 --- a/modules/gui/macosx/menus/VLCStatusBarIcon.m +++ b/modules/gui/macosx/menus/VLCStatusBarIcon.m @@ -24,7 +24,6 @@ #import "VLCStatusBarIcon.h" #import <vlc_common.h> -#import <vlc_playlist_legacy.h> #import <vlc_input.h> #import <vlc_url.h> diff --git a/modules/gui/macosx/panels/VLCAudioEffectsWindowController.m b/modules/gui/macosx/panels/VLCAudioEffectsWindowController.m index a61994c650..3190320a4a 100644 --- a/modules/gui/macosx/panels/VLCAudioEffectsWindowController.m +++ b/modules/gui/macosx/panels/VLCAudioEffectsWindowController.m @@ -29,6 +29,7 @@ #import <vlc_common.h> #import <math.h> +#import <vlc_playlist_legacy.h> #import "../../../audio_filter/equalizer_presets.h" @@ -38,6 +39,8 @@ #import "panels/dialogs/VLCPopupPanelController.h" #import "panels/dialogs/VLCTextfieldPanelController.h" +#import "extensions/helpers.h" + #pragma mark - #pragma mark Initialization diff --git a/modules/gui/macosx/panels/VLCBookmarksWindowController.m b/modules/gui/macosx/panels/VLCBookmarksWindowController.m index 4d9cf88500..f4ad7c786c 100644 --- a/modules/gui/macosx/panels/VLCBookmarksWindowController.m +++ b/modules/gui/macosx/panels/VLCBookmarksWindowController.m @@ -36,6 +36,7 @@ #import "VLCBookmarksWindowController.h" #import "main/CompatibilityFixes.h" +#import <vlc_playlist_legacy.h> @interface VLCBookmarksWindowController() <NSTableViewDataSource, NSTableViewDelegate> { diff --git a/modules/gui/macosx/panels/VLCInformationWindowController.m b/modules/gui/macosx/panels/VLCInformationWindowController.m index 72e6f7499e..fb9c8bc69c 100644 --- a/modules/gui/macosx/panels/VLCInformationWindowController.m +++ b/modules/gui/macosx/panels/VLCInformationWindowController.m @@ -377,8 +377,7 @@ FREENULL( psz_##foo ); input_item_SetDescription( _mediaItem, utf8( _descriptionTextField ) ); input_item_SetLanguage( _mediaItem, utf8( _languageTextField ) ); - playlist_t *p_playlist = pl_Get(getIntf()); - input_item_WriteMeta(VLC_OBJECT(p_playlist), _mediaItem); + input_item_WriteMeta(VLC_OBJECT(getIntf()), _mediaItem); [self updatePanelWithItem: _mediaItem]; diff --git a/modules/gui/macosx/panels/VLCTrackSynchronizationWindowController.m b/modules/gui/macosx/panels/VLCTrackSynchronizationWindowController.m index c64216bd6d..6f58bcdc83 100644 --- a/modules/gui/macosx/panels/VLCTrackSynchronizationWindowController.m +++ b/modules/gui/macosx/panels/VLCTrackSynchronizationWindowController.m @@ -28,6 +28,8 @@ #import "coreinteraction/VLCVideoFilterHelper.h" #import "main/CompatibilityFixes.h" #import "main/VLCMain.h" +#import <vlc_playlist_legacy.h> +#import "extensions/helpers.h" #define SUBSDELAY_CFG_MODE "subsdelay-mode" #define SUBSDELAY_CFG_FACTOR "subsdelay-factor" diff --git a/modules/gui/macosx/panels/VLCVideoEffectsWindowController.m b/modules/gui/macosx/panels/VLCVideoEffectsWindowController.m index 8c1b880f0f..da54d5629a 100644 --- a/modules/gui/macosx/panels/VLCVideoEffectsWindowController.m +++ b/modules/gui/macosx/panels/VLCVideoEffectsWindowController.m @@ -30,6 +30,9 @@ #import "panels/dialogs/VLCPopupPanelController.h" #import "panels/dialogs/VLCTextfieldPanelController.h" +#import <vlc_playlist_legacy.h> +#import "extensions/helpers.h" + #define getWidgetBoolValue(w) ((vlc_value_t){ .b_bool = [w state] }) #define getWidgetIntValue(w) ((vlc_value_t){ .i_int = [w intValue] }) #define getWidgetFloatValue(w) ((vlc_value_t){ .f_float = [w floatValue] }) diff --git a/modules/gui/macosx/windows/convertandsave/VLCConvertAndSaveWindowController.m b/modules/gui/macosx/windows/convertandsave/VLCConvertAndSaveWindowController.m index ffda7b877e..247f259d30 100644 --- a/modules/gui/macosx/windows/convertandsave/VLCConvertAndSaveWindowController.m +++ b/modules/gui/macosx/windows/convertandsave/VLCConvertAndSaveWindowController.m @@ -29,6 +29,7 @@ #import <vlc_common.h> #import <vlc_url.h> +#import <vlc_playlist_legacy.h> /* mini doc: * the used NSMatrix includes a bunch of cells referenced most easily by tags. There you go: */ diff --git a/modules/gui/macosx/windows/mainwindow/VLCControlsBarCommon.m b/modules/gui/macosx/windows/mainwindow/VLCControlsBarCommon.m index cfdc2c6d2a..8cb40daf69 100644 --- a/modules/gui/macosx/windows/mainwindow/VLCControlsBarCommon.m +++ b/modules/gui/macosx/windows/mainwindow/VLCControlsBarCommon.m @@ -31,6 +31,8 @@ #import "playlist/VLCPlaylistController.h" #import "playlist/VLCPlayerController.h" +#import <vlc_playlist_legacy.h> + /***************************************************************************** * VLCControlsBarCommon * diff --git a/modules/gui/macosx/windows/mainwindow/VLCMainWindowControlsBar.m b/modules/gui/macosx/windows/mainwindow/VLCMainWindowControlsBar.m index dc996fd7e5..29e96eb178 100644 --- a/modules/gui/macosx/windows/mainwindow/VLCMainWindowControlsBar.m +++ b/modules/gui/macosx/windows/mainwindow/VLCMainWindowControlsBar.m @@ -31,6 +31,7 @@ #import "menus/VLCMainMenu.h" #import "windows/mainwindow/VLCMainWindowControlsBar.h" +#import <vlc_playlist_legacy.h> /***************************************************************************** * VLCMainWindowControlsBar diff --git a/modules/gui/macosx/windows/video/VLCFSPanelController.m b/modules/gui/macosx/windows/video/VLCFSPanelController.m index 1c44138dfc..316c909ddd 100644 --- a/modules/gui/macosx/windows/video/VLCFSPanelController.m +++ b/modules/gui/macosx/windows/video/VLCFSPanelController.m @@ -26,6 +26,7 @@ #import "VLCFSPanelController.h" #import <vlc_aout.h> +#import <vlc_playlist_legacy.h> #import "coreinteraction/VLCCoreInteraction.h" #import "main/CompatibilityFixes.h" diff --git a/modules/gui/macosx/windows/video/VLCVideoOutputProvider.m b/modules/gui/macosx/windows/video/VLCVideoOutputProvider.m index 3339229933..3531406fdf 100644 --- a/modules/gui/macosx/windows/video/VLCVideoOutputProvider.m +++ b/modules/gui/macosx/windows/video/VLCVideoOutputProvider.m @@ -24,6 +24,7 @@ #import "VLCVideoOutputProvider.h" #include <vlc_vout_display.h> +#import <vlc_playlist_legacy.h> #import "extensions/NSScreen+VLCAdditions.h" diff --git a/modules/gui/macosx/windows/video/VLCVideoWindowCommon.m b/modules/gui/macosx/windows/video/VLCVideoWindowCommon.m index 8380be27bc..c90a9cc91a 100644 --- a/modules/gui/macosx/windows/video/VLCVideoWindowCommon.m +++ b/modules/gui/macosx/windows/video/VLCVideoWindowCommon.m @@ -29,6 +29,9 @@ #import "main/VLCMain.h" #import "windows/mainwindow/VLCControlsBarCommon.h" #import "windows/mainwindow/VLCMainWindow.h" +#import "windows/video/VLCVoutView.h" +#import <vlc_playlist_legacy.h> +#import "extensions/helpers.h" /***************************************************************************** * VLCVideoWindowCommon diff --git a/modules/gui/macosx/windows/video/VLCVoutView.m b/modules/gui/macosx/windows/video/VLCVoutView.m index 78b5d41bde..3f3d484739 100644 --- a/modules/gui/macosx/windows/video/VLCVoutView.m +++ b/modules/gui/macosx/windows/video/VLCVoutView.m @@ -43,6 +43,8 @@ #import "main/VLCMain.h" #import "menus/VLCMainMenu.h" +#import <vlc_playlist_legacy.h> + /***************************************************************************** * VLCVoutView implementation *****************************************************************************/ diff --git a/modules/gui/macosx/windows/video/VLCWindow.m b/modules/gui/macosx/windows/video/VLCWindow.m index bf70299746..569e586493 100644 --- a/modules/gui/macosx/windows/video/VLCWindow.m +++ b/modules/gui/macosx/windows/video/VLCWindow.m @@ -26,6 +26,7 @@ #import "main/CompatibilityFixes.h" #import "main/VLCMain.h" #import "windows/video/VLCVideoWindowCommon.h" +#import "windows/video/VLCVoutView.h" /***************************************************************************** * VLCWindow _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
