@@ -63,6 +63,7 @@ GuiConfDialog_t::GuiConfDialog_t(QWidget *parent)
6363 QGroupBox *frame, *qssFrame;
6464 QFrame *hline;
6565 std::string qssFile, qpalFile;
66+ QSettings settings;
6667
6768 // resize( 512, 600 );
6869 // printf("Style: %s \n", style()->objectName().toStdString().c_str() );
@@ -128,16 +129,19 @@ GuiConfDialog_t::GuiConfDialog_t(QWidget *parent)
128129 useNativeMenuBar = new QCheckBox (tr (" Use Native OS Menu Bar" ));
129130 pauseOnMenuAccess = new QCheckBox (tr (" Pause On Main Menu Access" ));
130131 ctxMenuEnable = new QCheckBox (tr (" Context Menu Enable" ));
132+ showSplashScreen = new QCheckBox (tr (" Show Splash Screen at Startup" ));
131133
132134 useNativeFileDialog->setChecked (useNativeFileDialogVal);
133135 useNativeMenuBar->setChecked (useNativeMenuBarVal);
134136 pauseOnMenuAccess->setChecked (pauseOnMenuAccessVal);
135137 ctxMenuEnable->setChecked (contextMenuEnable);
138+ showSplashScreen->setChecked ( settings.value (" mainWindow/showSplashScreen" , false ).toBool () );
136139
137140 connect (useNativeFileDialog, SIGNAL (stateChanged (int )), this , SLOT (useNativeFileDialogChanged (int )));
138141 connect (useNativeMenuBar , SIGNAL (stateChanged (int )), this , SLOT (useNativeMenuBarChanged (int )));
139142 connect (pauseOnMenuAccess , SIGNAL (stateChanged (int )), this , SLOT (pauseOnMenuAccessChanged (int )));
140143 connect (ctxMenuEnable , SIGNAL (stateChanged (int )), this , SLOT (contextMenuEnableChanged (int )));
144+ connect (showSplashScreen , SIGNAL (stateChanged (int )), this , SLOT (showSplashScreenChanged (int )));
141145
142146 styleComboBox = new QComboBox ();
143147
@@ -239,6 +243,7 @@ GuiConfDialog_t::GuiConfDialog_t(QWidget *parent)
239243 vbox1->addWidget (useNativeMenuBar, 1 );
240244 vbox1->addWidget (pauseOnMenuAccess, 1 );
241245 vbox1->addWidget (ctxMenuEnable, 1 );
246+ vbox1->addWidget (showSplashScreen, 1 );
242247 vbox1->addStretch (10 );
243248
244249 closeButton = new QPushButton ( tr (" Close" ) );
@@ -310,6 +315,15 @@ void GuiConfDialog_t::contextMenuEnableChanged(int state)
310315 consoleWindow->setContextMenuEnable ( value );
311316}
312317// ----------------------------------------------------
318+ void GuiConfDialog_t::showSplashScreenChanged (int state)
319+ {
320+ QSettings settings;
321+ bool value = (state == Qt::Unchecked) ? 0 : 1 ;
322+
323+ settings.setValue (" mainWindow/showSplashScreen" , value );
324+ settings.sync ();
325+ }
326+ // ----------------------------------------------------
313327void GuiConfDialog_t::useCustomStyleChanged (int state)
314328{
315329 int value = (state == Qt::Unchecked) ? 0 : 1 ;
0 commit comments