diff --git a/app/main.cpp b/app/main.cpp --- a/app/main.cpp +++ b/app/main.cpp @@ -38,6 +38,7 @@ // Local #include #include +#include #include "mainwindow.h" #ifdef HAVE_FITS @@ -151,7 +152,9 @@ // startHelper must live for the whole life of the application StartHelper startHelper(parser.positionalArguments(), - parser.isSet(QStringLiteral("f")), + parser.isSet(QStringLiteral("f")) + ? true + : Gwenview::GwenviewConfig::fullScreenModeActive(), parser.isSet(QStringLiteral("s"))); if (app.isSessionRestored()) { kRestoreMainWindows(); diff --git a/app/mainwindow.cpp b/app/mainwindow.cpp --- a/app/mainwindow.cpp +++ b/app/mainwindow.cpp @@ -1491,6 +1491,7 @@ d->mViewMainPage->saveConfig(); d->mBrowseMainPage->saveConfig(); d->mContextManager->saveConfig(); + GwenviewConfig::setFullScreenModeActive(isFullScreen()); } void MainWindow::print() diff --git a/lib/gwenviewconfig.kcfg b/lib/gwenviewconfig.kcfg --- a/lib/gwenviewconfig.kcfg +++ b/lib/gwenviewconfig.kcfg @@ -114,6 +114,9 @@ true + + false +