Commit ccacddbd authored by Clément Stenac's avatar Clément Stenac

* Fix crash

* Add a prefs button
parent 04e52ef4
...@@ -60,7 +60,6 @@ PrefsDialog::PrefsDialog( intf_thread_t *_p_intf ) : QVLCFrame( _p_intf ) ...@@ -60,7 +60,6 @@ PrefsDialog::PrefsDialog( intf_thread_t *_p_intf ) : QVLCFrame( _p_intf )
types->setLayout(tl ); types->setLayout(tl );
layout->addLayout( vertical, 1 ); layout->addLayout( vertical, 1 );
setAll();
all->setChecked( true ); all->setChecked( true );
...@@ -68,6 +67,8 @@ PrefsDialog::PrefsDialog( intf_thread_t *_p_intf ) : QVLCFrame( _p_intf ) ...@@ -68,6 +67,8 @@ PrefsDialog::PrefsDialog( intf_thread_t *_p_intf ) : QVLCFrame( _p_intf )
adv_chk = new QCheckBox("Advanced options"); adv_chk = new QCheckBox("Advanced options");
main_layout->addWidget( adv_chk ); main_layout->addWidget( adv_chk );
setAll();
QObject::connect( adv_chk, SIGNAL( toggled(bool) ), this, QObject::connect( adv_chk, SIGNAL( toggled(bool) ), this,
SLOT( setAdvanced( bool ) ) ); SLOT( setAdvanced( bool ) ) );
setLayout( main_layout ); setLayout( main_layout );
......
...@@ -26,6 +26,7 @@ ...@@ -26,6 +26,7 @@
#include "dialogs_provider.hpp" #include "dialogs_provider.hpp"
#include <QCloseEvent> #include <QCloseEvent>
#include <assert.h> #include <assert.h>
#include <QPushButton>
MainInterface::MainInterface( intf_thread_t *_p_intf ) : MainInterface::MainInterface( intf_thread_t *_p_intf ) :
QWidget( NULL ), p_intf( _p_intf) QWidget( NULL ), p_intf( _p_intf)
...@@ -36,6 +37,12 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) : ...@@ -36,6 +37,12 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) :
/* Init input manager */ /* Init input manager */
p_input = NULL; p_input = NULL;
main_input_manager = new InputManager( this, p_intf ); main_input_manager = new InputManager( this, p_intf );
QPushButton *button = new QPushButton( "prefs", this );
QObject::connect( button, SIGNAL( clicked() ),
DialogsProvider::getInstance(p_intf), SLOT( prefsDialog() ) );
} }
void MainInterface::init() void MainInterface::init()
......
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