diff --git a/GeometryView.cpp b/GeometryView.cpp index e90e548..fd2ddd9 100644 --- a/GeometryView.cpp +++ b/GeometryView.cpp @@ -48,13 +48,12 @@ GeometryView::GeometryView() : View(GEOMETRY) { scene.root()->scale_ = glm::vec3(GEOMETRY_DEFAULT_SCALE, GEOMETRY_DEFAULT_SCALE, 1.0f); // read default settings - if ( Settings::application.views[mode_].name.empty() ) { + if ( Settings::application.views[mode_].name.empty() ) // no settings found: store application default - Settings::application.views[mode_].name = "Geometry"; saveSettings(); - } else restoreSettings(); + Settings::application.views[mode_].name = "Geometry"; // Geometry Scene foreground output_surface_ = new Surface; diff --git a/LayerView.cpp b/LayerView.cpp index 1b98d7d..c4be552 100644 --- a/LayerView.cpp +++ b/LayerView.cpp @@ -46,14 +46,12 @@ LayerView::LayerView() : View(LAYER), aspect_ratio(1.f) scene.root()->scale_ = glm::vec3(LAYER_DEFAULT_SCALE, LAYER_DEFAULT_SCALE, 1.0f); scene.root()->translation_ = glm::vec3(2.2f, 1.2f, 0.0f); // read default settings - if ( Settings::application.views[mode_].name.empty() ) { + if ( Settings::application.views[mode_].name.empty() ) // no settings found: store application default - Settings::application.views[mode_].name = "Layer"; saveSettings(); - } - else { + else restoreSettings(); - } + Settings::application.views[mode_].name = "Layer"; // Geometry Scene background frame_ = new Group; diff --git a/MixingView.cpp b/MixingView.cpp index 778f443..2b2bfdc 100644 --- a/MixingView.cpp +++ b/MixingView.cpp @@ -53,13 +53,12 @@ MixingView::MixingView() : View(MIXING), limbo_scale_(MIXING_MIN_THRESHOLD) scene.root()->scale_ = glm::vec3(MIXING_DEFAULT_SCALE, MIXING_DEFAULT_SCALE, 1.0f); scene.root()->translation_ = glm::vec3(0.0f, 0.0f, 0.0f); // read default settings - if ( Settings::application.views[mode_].name.empty() ) { + if ( Settings::application.views[mode_].name.empty() ) // no settings found: store application default - Settings::application.views[mode_].name = "Mixing"; saveSettings(); - } else restoreSettings(); + Settings::application.views[mode_].name = "Mixing"; // Mixing scene background limbo_ = new Mesh("mesh/disk.ply"); diff --git a/TextureView.cpp b/TextureView.cpp index 9cdc543..2131bfc 100644 --- a/TextureView.cpp +++ b/TextureView.cpp @@ -50,13 +50,12 @@ TextureView::TextureView() : View(TEXTURE), edit_source_(nullptr), need_edit_upd scene.root()->scale_ = glm::vec3(APPEARANCE_DEFAULT_SCALE, APPEARANCE_DEFAULT_SCALE, 1.0f); scene.root()->translation_ = glm::vec3(0.8f, 0.f, 0.0f); // read default settings - if ( Settings::application.views[mode_].name.empty() ) { + if ( Settings::application.views[mode_].name.empty() ) // no settings found: store application default - Settings::application.views[mode_].name = "Texture"; saveSettings(); - } else restoreSettings(); + Settings::application.views[mode_].name = "Texturing"; // // Scene background diff --git a/TransitionView.cpp b/TransitionView.cpp index f20cc0e..31d3b90 100644 --- a/TransitionView.cpp +++ b/TransitionView.cpp @@ -48,13 +48,13 @@ TransitionView::TransitionView() : View(TRANSITION), transition_source_(nullptr) if ( Settings::application.views[mode_].name.empty() ) { // no settings found: store application default - Settings::application.views[mode_].name = "Transition"; scene.root()->scale_ = glm::vec3(TRANSITION_DEFAULT_SCALE, TRANSITION_DEFAULT_SCALE, 1.0f); scene.root()->translation_ = glm::vec3(1.5f, 0.f, 0.0f); saveSettings(); } else restoreSettings(); + Settings::application.views[mode_].name = "Transition"; // Geometry Scene background gradient_ = new Switch;