Permalink
Browse files

disable state loading for elements deemed dangerous

affects open docks/viewports, selected false coloring
temporary action until new data handling is incorporated
see #34
  • Loading branch information...
ypnos committed Feb 19, 2017
1 parent 6faeb91 commit 94f704447b5ce2dcd77019a641d96382dcb174a7
Showing with 9 additions and 4 deletions.
  1. +3 −2 gui/controller/controller_docks.cpp
  2. +1 −1 gui/controller/distviewcontroller.cpp
  3. +5 −1 gui/docks/falsecolordock.cpp
@@ -53,8 +53,9 @@ void Controller::initDocks()
#endif
roiDock->raise();
// restore dock widget positions
- mainWindow()->restoreState(
- settings.value("mainWindow/windowState").toByteArray());
+ if (false) /* TODO: disabled to avoid crashes */
+ mainWindow()->restoreState(
+ settings.value("mainWindow/windowState").toByteArray());
imageModel()->computeFullRgb();
}
@@ -46,7 +46,7 @@ void DistViewController::init()
// NOTE that we did not connect signals yet! This is actually good as we
// will not get stray signals before the content is ready.
QSettings settings;
- if (settings.contains("viewports/IMGfolded")) {
+ if (false && settings.contains("viewports/IMGfolded")) { /* TODO: disabled to avoid crashes */
// settings are available
QString activeStr = settings.value("viewports/active").value<QString>();
activeView = representation::fromStr(activeStr);
@@ -386,7 +386,11 @@ void FalseColorDock::restoreState()
auto selectedColoring = settings.value("FalseColorDock/selectedColoringIndex", 0);
QComboBox *src = uisel->sourceBox;
- src->setCurrentIndex(selectedColoring.toInt());
+ /* TODO: disabled to avoid crashes */
+ if (false)
+ src->setCurrentIndex(selectedColoring.toInt());
+ else
+ src->setCurrentIndex(0);
processSelectedColoring();
// TODO: state of spectral distance map

0 comments on commit 94f7044

Please sign in to comment.