From 62a5ad33bd5526a093175a3cdf51730c587464d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Fauconnier?= Date: Tue, 19 Feb 2019 16:08:09 +0100 Subject: [PATCH] added possibility to start in Document Mode --- resources/forms/preferences.ui | 7 ++++++- src/core/UBApplication.cpp | 8 +++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/resources/forms/preferences.ui b/resources/forms/preferences.ui index d1cfc113..9b99077d 100644 --- a/resources/forms/preferences.ui +++ b/resources/forms/preferences.ui @@ -82,7 +82,7 @@ - 7 + 0 @@ -387,6 +387,11 @@ Desktop + + + Document + + diff --git a/src/core/UBApplication.cpp b/src/core/UBApplication.cpp index 194ea6e4..c8692290 100644 --- a/src/core/UBApplication.cpp +++ b/src/core/UBApplication.cpp @@ -351,10 +351,12 @@ int UBApplication::exec(const QString& pFileToImport) if (pFileToImport.length() > 0) UBApplication::applicationController->importFile(pFileToImport); - if (UBSettings::settings()->appStartMode->get().toInt()) - applicationController->showDesktop(); - else + if (UBSettings::settings()->appStartMode->get().toInt() == 0) applicationController->showBoard(); + else if (UBSettings::settings()->appStartMode->get().toInt() == 1) + applicationController->showDesktop(); + else if (UBSettings::settings()->appStartMode->get().toInt() == 2) + applicationController->showDocument(); emit UBDrawingController::drawingController()->colorPaletteChanged();