Remove blocking call in KStatusNotifierItem
AbandonedPublic

Authored by davidedmundson on Oct 17 2017, 5:41 PM.

Details

Reviewers
None
Summary

BUG: 385867

Test Plan

Ran test
killed plasmashell
SNI restored when plasmashell came back

Diff Detail

Repository
R289 KNotifications
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
davidedmundson created this revision.Oct 17 2017, 5:41 PM
Restricted Application added a project: Frameworks. · View Herald TranscriptOct 17 2017, 5:41 PM
Restricted Application added a subscriber: Frameworks. · View Herald Transcript
xuetianweng added inline comments.
src/kstatusnotifieritem.cpp
879

Do you need the extra dot at the end of "org.freedesktop.DBus.Properties." ?

davidedmundson planned changes to this revision.Oct 17 2017, 5:52 PM
xuetianweng added inline comments.Oct 17 2017, 5:58 PM
src/kstatusnotifieritem.cpp
882

The template is not necessary here. Maybe auto or QDBusPendingCall ?

883

I prefer to assign a parent to the watcher. Maybe "q"?

884

watcher can be obtained via the argument of this signal, no need to capture it.

I've realised there's much more to do:

The existing code has some super weird behaviour.

Find there's an SNI watcher, but no host (i.e kded but no plasmashell) - that's fine, we don't check and create one anyway
But if a host gets added/removed - then we check

That makes no sense.

IMHO, there's no point checking for hosts, if we have an SNI watcher, we're clearly on a system that supports SNIs, even if the view temporarily disappears.
At which point I should just kill this code.

davidedmundson abandoned this revision.Oct 18 2017, 9:18 AM