Hide printer applet if no printer is configured
ClosedPublic

Authored by broulik on Sep 7 2018, 9:01 AM.

Details

Summary

Having a printer is less common these days and having a tray icon sitting there in the popup all the time clutters the list.

Test Plan
  • Verified that plasmoid is hidden when no printer is set up
  • Verified that plasmoid is passive (hidden in popup) when printers are set up but no print job is active
  • Verified that plasmoid is active (shows in panel) when print job is active
  • Verified that error case still works (since I moved the jobModelError to root)
  • Verified that serach box (only shows if there are many printers) still works

Ideally print-manager's kded module would expose some dbus service so we don't even load the plasmoid if no printer is configured but from what I can tell the kded module doesn't actually connect to cups but just listens to some dbus signals, so the gain is less than expected, it's either kded doing it or plasma doing it or both if printers then end up being configured

Diff Detail

Repository
R363 Print Manager
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
broulik created this revision.Sep 7 2018, 9:01 AM
Restricted Application added a subscriber: kde-utils-devel. · View Herald TranscriptSep 7 2018, 9:01 AM
broulik requested review of this revision.Sep 7 2018, 9:01 AM
broulik edited the test plan for this revision. (Show Details)

Good idea from ux point of view

cfeck added a subscriber: cfeck.Sep 7 2018, 12:29 PM

Does adding a printer show the entry?

Does adding a printer show the entry?

Installing a printer through the KCM (or when one is auto-discovered) will make the entry appear in the System Tray popup. Uninstalling all printers makes it go away again.

ngraham accepted this revision as: VDG.EditedSep 7 2018, 1:36 PM
ngraham added a subscriber: ngraham.

I think this makes sense the way you've broken it down:

  • Visible on panel when in use
  • Hidden on panel but shown in pop-up when not in use but has been configured
  • Hidden everywhere when no printers are configured
dantti accepted this revision.Sep 10 2018, 2:20 PM
dantti added a subscriber: dantti.

LGTM

This revision is now accepted and ready to land.Sep 10 2018, 2:20 PM
This revision was automatically updated to reflect the committed changes.