Skip to content
Commit 46e5b32e authored by Nate Graham's avatar Nate Graham
Browse files

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
parent 3d93d461
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment