Also allow invoking session restoration logic when apps are manually launched
Summary:
Right now session restoration logic only ever gets invoked when apps are started
automatically after rebooting, because of the check for qApp->isSessionRestored().
This limits the feature to only working for that use case, since qApp->isSessionRestored()
is set by Qt and we can't override it in the app itself to signal that we want the session
restoration behavior for other reasons. As a result, we can't use it to implement the
behavior of restoring the condition of app when it's manually launched, which has been
requested for several of our apps.
This patch removes the check for qApp->isSessionRestored(), which opens the door to
implementing the requested features in our apps.
CCBUG: 397463
CCBUG: 413564
Test Plan:
D11382 now works
Normal session restoration behavior after a reboot is unchanged
Apps with session restoration behavior but without a user-facing option to invoke it
don't restore session at inappropriate times.
Reviewers: davidedmundson, Frameworks
Reviewed By: davidedmundson
Subscribers: kde-frameworks-devel
Tags: Frameworks
Differential Revision: https://phabricator.kde.org/D25106