D25106: Also allow invoking session restoration logic when apps are manually launched

Nathaniel Graham noreply at phabricator.kde.org
Fri Nov 1 15:28:38 GMT 2019


ngraham created this revision.
ngraham added reviewers: davidedmundson, Frameworks.
Herald added a project: Frameworks.
Herald added a subscriber: kde-frameworks-devel.
ngraham requested review of this revision.

REVISION 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 <https://phabricator.kde.org/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.

REPOSITORY
  R263 KXmlGui

BRANCH
  allow-restoring-session-manually (branched from master)

REVISION DETAIL
  https://phabricator.kde.org/D25106

AFFECTED FILES
  src/kmainwindow.cpp

To: ngraham, davidedmundson, #frameworks
Cc: kde-frameworks-devel, LeGast00n, GB_2, michaelh, ngraham, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20191101/c878beb2/attachment.html>


More information about the Kde-frameworks-devel mailing list