From f5af24b3849813cfc157d1ff1eee2a70706d7cfe Mon Sep 17 00:00:00 2001 From: brunoherbelin Date: Tue, 13 Apr 2021 21:27:51 +0200 Subject: [PATCH] Update settings --- Settings.cpp | 4 ++-- Settings.h | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Settings.cpp b/Settings.cpp index 57ec707..f54bcba 100644 --- a/Settings.cpp +++ b/Settings.cpp @@ -63,11 +63,11 @@ void Settings::Save() XMLElement *applicationNode = xmlDoc.NewElement( "Application" ); applicationNode->SetAttribute("scale", application.scale); applicationNode->SetAttribute("accent_color", application.accent_color); - applicationNode->SetAttribute("pannel_stick", application.pannel_stick); applicationNode->SetAttribute("smooth_transition", application.smooth_transition); applicationNode->SetAttribute("smooth_cursor", application.smooth_cursor); applicationNode->SetAttribute("action_history_follow_view", application.action_history_follow_view); applicationNode->SetAttribute("accept_connections", application.accept_connections); + applicationNode->SetAttribute("pannel_history_mode", application.pannel_history_mode); pRoot->InsertEndChild(applicationNode); // Widgets @@ -254,11 +254,11 @@ void Settings::Load() if (applicationNode != nullptr) { applicationNode->QueryFloatAttribute("scale", &application.scale); applicationNode->QueryIntAttribute("accent_color", &application.accent_color); - applicationNode->QueryBoolAttribute("pannel_stick", &application.pannel_stick); applicationNode->QueryBoolAttribute("smooth_transition", &application.smooth_transition); applicationNode->QueryBoolAttribute("smooth_cursor", &application.smooth_cursor); applicationNode->QueryBoolAttribute("action_history_follow_view", &application.action_history_follow_view); applicationNode->QueryBoolAttribute("accept_connections", &application.accept_connections); + applicationNode->QueryIntAttribute("pannel_history_mode", &application.pannel_history_mode); } // Widgets diff --git a/Settings.h b/Settings.h index 253a586..8d797ae 100644 --- a/Settings.h +++ b/Settings.h @@ -178,14 +178,14 @@ struct Application // Global settings Application interface float scale; int accent_color; - bool pannel_stick; bool smooth_transition; bool smooth_cursor; bool action_history_follow_view; + int pannel_history_mode; + // connection settings bool accept_connections; -// std::map instance_names; // Settings of widgets WidgetsConfig widget; @@ -221,11 +221,11 @@ struct Application Application() : fresh_start(false), instance_id(0), name(APP_NAME), executable(APP_NAME) { scale = 1.f; accent_color = 0; - pannel_stick = false; smooth_transition = true; smooth_cursor = false; action_history_follow_view = false; accept_connections = false; + pannel_history_mode = 0; current_view = 1; current_workspace= 1; brush = glm::vec3(0.5f, 0.1f, 0.f);