D23279: [Lock screen] Fix bug causing "Switch User" button to always be visible

Nathaniel Graham noreply at phabricator.kde.org
Mon Aug 19 23:05:44 BST 2019


ngraham created this revision.
ngraham added reviewers: mart, Plasma.
Herald added a project: Plasma.
Herald added a subscriber: plasma-devel.
ngraham requested review of this revision.

REVISION SUMMARY
  The code clearly intended for the Switch User button to only be visible when there
  was more than one session, but a subtle bug prevented this from working: the fake "new
  session" session that's added to the model increases its size by one, making the
  conditional always true.
  
  This patch fixes the bug by testing against a number appropriate for whether or not
  the fake "new session" session exists, since it's configurable.

TEST PLAN
  No more Switch User button on the login screen unless there are multiple sessions

REPOSITORY
  R120 Plasma Workspace

BRANCH
  only-show-switch-user-button-when-more-than-one-session-is-active (branched from master)

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

AFFECTED FILES
  lookandfeel/contents/lockscreen/LockScreenUi.qml

To: ngraham, mart, #plasma
Cc: plasma-devel, LeGast00n, The-Feren-OS-Dev, jraleigh, fbampaloukas, GB_2, ragreen, Pitel, ZrenBot, himcesjf, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20190819/fa3a6b74/attachment-0001.html>


More information about the Plasma-devel mailing list