Commit 305917c3 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt: add the playlist view selection to the main menu

parent 6bb65f65
...@@ -57,10 +57,12 @@ public: ...@@ -57,10 +57,12 @@ public:
void forceHide(); void forceHide();
void forceShow(); void forceShow();
QStackedWidget *artContainer; QStackedWidget *artContainer;
StandardPLPanel *mainView;
private: private:
QSplitter *leftSplitter; QSplitter *leftSplitter;
QSplitter *split; QSplitter *split;
StandardPLPanel *mainView;
PLSelector *selector; PLSelector *selector;
LocationBar *locationBar; LocationBar *locationBar;
......
...@@ -936,6 +936,12 @@ int MainInterface::getControlsVisibilityStatus() ...@@ -936,6 +936,12 @@ int MainInterface::getControlsVisibilityStatus()
+ CONTROLS_ADVANCED * controls->b_advancedVisible ); + CONTROLS_ADVANCED * controls->b_advancedVisible );
} }
StandardPLPanel *MainInterface::getPlaylistView()
{
if( !playlistWidget ) return NULL;
else return playlistWidget->mainView;
}
void MainInterface::setStatusBarVisibility( bool b_visible ) void MainInterface::setStatusBarVisibility( bool b_visible )
{ {
statusBar()->setVisible( b_visible ); statusBar()->setVisible( b_visible );
......
...@@ -54,6 +54,7 @@ class SpeedControlWidget; ...@@ -54,6 +54,7 @@ class SpeedControlWidget;
class QVBoxLayout; class QVBoxLayout;
class QMenu; class QMenu;
class QSize; class QSize;
class StandardPLPanel;
enum { enum {
CONTROLS_VISIBLE = 0x1, CONTROLS_VISIBLE = 0x1,
...@@ -87,6 +88,7 @@ public: ...@@ -87,6 +88,7 @@ public:
int getControlsVisibilityStatus(); int getControlsVisibilityStatus();
bool isPlDocked() { return ( b_plDocked != false ); } bool isPlDocked() { return ( b_plDocked != false ); }
bool isInterfaceFullScreen() { return b_interfaceFullScreen; } bool isInterfaceFullScreen() { return b_interfaceFullScreen; }
StandardPLPanel* getPlaylistView();
protected: protected:
void dropEventPlay( QDropEvent* event, bool b_play ) { dropEventPlay(event, b_play, true); } void dropEventPlay( QDropEvent* event, bool b_play ) { dropEventPlay(event, b_play, true); }
......
...@@ -49,6 +49,7 @@ ...@@ -49,6 +49,7 @@
#include "extensions_manager.hpp" /* Extensions menu */ #include "extensions_manager.hpp" /* Extensions menu */
#include "util/qmenuview.hpp" /* Simple Playlist menu */ #include "util/qmenuview.hpp" /* Simple Playlist menu */
#include "components/playlist/playlist_model.hpp" /* PLModel getter */ #include "components/playlist/playlist_model.hpp" /* PLModel getter */
#include "components/playlist/standardpanel.hpp" /* PLView getter */
#include <QMenu> #include <QMenu>
#include <QMenuBar> #include <QMenuBar>
...@@ -474,6 +475,8 @@ QMenu *VLCMenuBar::ViewMenu( intf_thread_t *p_intf, QMenu *current, MainInterfac ...@@ -474,6 +475,8 @@ QMenu *VLCMenuBar::ViewMenu( intf_thread_t *p_intf, QMenu *current, MainInterfac
qtr( "Play&list" ), mi, qtr( "Play&list" ), mi,
SLOT( togglePlaylist() ), qtr( "Ctrl+L" ) ); SLOT( togglePlaylist() ), qtr( "Ctrl+L" ) );
if( mi->getPlaylistView() )
menu->addMenu( StandardPLPanel::viewSelectionMenu( mi->getPlaylistView() ) );
menu->addSeparator(); menu->addSeparator();
/* Minimal View */ /* Minimal View */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment