comparison src/main.cpp @ 382:a5e63c0af39a tonioni_experiment_july2014 v0.7_experiment_july2014

Fix to settings reset -- needs to happen before the MainWindow ctor to avoid breaking behaviour within the current run!
author Chris Cannam
date Mon, 21 Jul 2014 15:23:10 +0100
parents 08769d8e46f0
children
comparison
equal deleted inserted replaced
381:5641917aea9c 382:a5e63c0af39a
165 165
166 QApplication::setOrganizationName("QMUL"); 166 QApplication::setOrganizationName("QMUL");
167 QApplication::setOrganizationDomain("qmul.ac.uk"); 167 QApplication::setOrganizationDomain("qmul.ac.uk");
168 QApplication::setApplicationName("Tony"); 168 QApplication::setApplicationName("Tony");
169 169
170 {
171 //!!! For Tony experiments:
172 QSettings settings;
173 settings.clear();
174 settings.sync();
175 }
176
170 InteractiveFileFinder::getInstance()->setApplicationSessionExtension("ton"); 177 InteractiveFileFinder::getInstance()->setApplicationSessionExtension("ton");
171 178
172 QSplashScreen *splash = 0; 179 QSplashScreen *splash = 0;
173 // If we had a splash screen, we would show it here 180 // If we had a splash screen, we would show it here
174 181
214 221
215 int width = (available.width() * 2) / 3; 222 int width = (available.width() * 2) / 3;
216 int height = available.height() / 2; 223 int height = available.height() / 2;
217 if (height < 450) height = (available.height() * 2) / 3; 224 if (height < 450) height = (available.height() * 2) / 3;
218 if (width > height * 2) width = height * 2; 225 if (width > height * 2) width = height * 2;
219
220 {
221 //!!! For Tony experiments:
222 QSettings settings;
223 settings.clear();
224 settings.sync();
225 }
226 226
227 QSettings settings; 227 QSettings settings;
228 settings.beginGroup("MainWindow"); 228 settings.beginGroup("MainWindow");
229 QSize size = settings.value("size", QSize(width, height)).toSize(); 229 QSize size = settings.value("size", QSize(width, height)).toSize();
230 gui->resizeConstrained(size); 230 gui->resizeConstrained(size);