UISettings::UISettings( QList <supportedRes_struct> *supportedResolutions, QList <translation_struct> *translations, QWidget* p ) : QDialog( p ) { // setup dialog setupUi( this ); QRect maxWinRect = QApplication::desktop()->availableGeometry(); leWinWidth->setValidator(new QIntValidator(0, maxWinRect.width(), leWinWidth)); leWinHeight->setValidator(new QIntValidator(0, maxWinRect.height(), leWinHeight)); pmPort1->setPort( 1 ); pmPort1->loadSettings(); pmPort2->setPort( 2 ); pmPort2->loadSettings(); if ( p && !p->isFullScreen() ) { setWindowFlags( Qt::Sheet ); } setupCdDrives(); // load cores informations loadCores(); supportedRes = *supportedResolutions; loadSupportedResolutions(); #ifdef HAVE_LIBMINI18N trans = *translations; loadTranslations(); #else lTranslation->hide(); cbTranslation->hide(); #endif loadShortcuts(); // load settings loadSettings(); // connections foreach ( QToolButton* tb, findChildren<QToolButton*>() ) { connect( tb, SIGNAL( clicked() ), this, SLOT( tbBrowse_clicked() ) ); }
UISettings::UISettings( QList <supportedRes_struct> *supportedResolutions, QList <translation_struct> *translations, QWidget* p ) : QDialog( p ) { // setup dialog setupUi( this ); pmPort1->setPort( 1 ); pmPort1->loadSettings(); pmPort2->setPort( 2 ); pmPort2->loadSettings(); if ( p && !p->isFullScreen() ) { setWindowFlags( Qt::Sheet ); } setupCdDrives(); // load cores informations loadCores(); supportedRes = *supportedResolutions; loadSupportedResolutions(); #ifdef HAVE_LIBMINI18N trans = *translations; loadTranslations(); #else lTranslation->hide(); cbTranslation->hide(); #endif loadShortcuts(); // load settings loadSettings(); // connections foreach ( QToolButton* tb, findChildren<QToolButton*>() ) { connect( tb, SIGNAL( clicked() ), this, SLOT( tbBrowse_clicked() ) ); }