Commit 9b8667a8 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt: Extendedpanel: move to a Dialog

Close #5335
parent 586de2de
...@@ -36,7 +36,8 @@ ...@@ -36,7 +36,8 @@
#include <QPushButton> #include <QPushButton>
#include <vlc_modules.h> #include <vlc_modules.h>
ExtendedDialog::ExtendedDialog( intf_thread_t *_p_intf ): QVLCFrame( _p_intf ) ExtendedDialog::ExtendedDialog( intf_thread_t *_p_intf )
: QVLCDialog( (QWidget*)_p_intf->p_sys->p_mi, _p_intf )
{ {
#ifdef __APPLE__ #ifdef __APPLE__
setWindowFlags( Qt::Drawer ); setWindowFlags( Qt::Drawer );
...@@ -116,7 +117,7 @@ ExtendedDialog::ExtendedDialog( intf_thread_t *_p_intf ): QVLCFrame( _p_intf ) ...@@ -116,7 +117,7 @@ ExtendedDialog::ExtendedDialog( intf_thread_t *_p_intf ): QVLCFrame( _p_intf )
ExtendedDialog::~ExtendedDialog() ExtendedDialog::~ExtendedDialog()
{ {
writeSettings( "EPanel" ); getSettings()->setValue("Epanel/geometry", saveGeometry());
} }
void ExtendedDialog::showTab( int i ) void ExtendedDialog::showTab( int i )
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
class QTabWidget; class QTabWidget;
class ExtendedDialog : public QVLCFrame, public Singleton<ExtendedDialog> class ExtendedDialog : public QVLCDialog, public Singleton<ExtendedDialog>
{ {
Q_OBJECT Q_OBJECT
public: public:
......
...@@ -91,7 +91,6 @@ DialogsProvider::~DialogsProvider() ...@@ -91,7 +91,6 @@ DialogsProvider::~DialogsProvider()
PlaylistDialog::killInstance(); PlaylistDialog::killInstance();
MediaInfoDialog::killInstance(); MediaInfoDialog::killInstance();
MessagesDialog::killInstance(); MessagesDialog::killInstance();
ExtendedDialog::killInstance();
BookmarksDialog::killInstance(); BookmarksDialog::killInstance();
HelpDialog::killInstance(); HelpDialog::killInstance();
#ifdef UPDATE_CHECK #ifdef UPDATE_CHECK
...@@ -191,20 +190,24 @@ void DialogsProvider::prefsDialog() ...@@ -191,20 +190,24 @@ void DialogsProvider::prefsDialog()
void DialogsProvider::extendedDialog() void DialogsProvider::extendedDialog()
{ {
if( !ExtendedDialog::getInstance( p_intf )->isVisible() || /* Hidden */ ExtendedDialog *extDialog = ExtendedDialog::getInstance(p_intf );
ExtendedDialog::getInstance( p_intf )->currentTab() != 0 ) /* wrong tab */
ExtendedDialog::getInstance( p_intf )->showTab( 0 ); if( !extDialog->isVisible() || /* Hidden */
extDialog->currentTab() != 0 ) /* wrong tab */
extDialog->showTab( 0 );
else else
ExtendedDialog::getInstance( p_intf )->hide(); extDialog->hide();
} }
void DialogsProvider::synchroDialog() void DialogsProvider::synchroDialog()
{ {
if( !ExtendedDialog::getInstance( p_intf )->isVisible() || /* Hidden */ ExtendedDialog *extDialog = ExtendedDialog::getInstance(p_intf );
ExtendedDialog::getInstance( p_intf )->currentTab() != 2 ) /* wrong tab */
ExtendedDialog::getInstance( p_intf )->showTab( 2 ); if( !extDialog->isVisible() || /* Hidden */
extDialog->currentTab() != 2 ) /* wrong tab */
extDialog->showTab( 2 );
else else
ExtendedDialog::getInstance( p_intf )->hide(); extDialog->hide();
} }
void DialogsProvider::messagesDialog() void DialogsProvider::messagesDialog()
......
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