[krunner] Don't call KWindowSystem::setState on every event
ClosedPublic

Authored by graesslin on Mar 8 2016, 4:49 PM.

Details

Reviewers
broulik
Group Reviewers
Plasma
Summary

On Wayland that resulted in an endless recursion and also on X11 it's
a little bit too much to update the state on every event.

Let's only do it on the show event (as the comment states) and on
PlatformSurface created events

Test Plan

Doesn't crash on Wayland anymore, on X11 not tested.

Diff Detail

Repository
R120 Plasma Workspace
Lint
Lint Skipped
Unit
Unit Tests Skipped
graesslin updated this revision to Diff 2622.Mar 8 2016, 4:49 PM
graesslin retitled this revision from to [krunner] Don't call KWindowSystem::setState on every event.
graesslin updated this object.
graesslin edited the test plan for this revision. (Show Details)
graesslin added a reviewer: Plasma.
graesslin set the repository for this revision to R120 Plasma Workspace.
graesslin added a project: Plasma.
graesslin added a subscriber: Plasma.
Restricted Application added a subscriber: plasma-devel. ยท View Herald TranscriptMar 8 2016, 4:49 PM
broulik added a subscriber: broulik.Mar 8 2016, 7:22 PM
broulik added inline comments.
krunner/view.cpp
193

It can't be multiple types at once so you don't need that setState check there

graesslin marked an inline comment as done.Mar 8 2016, 7:34 PM

aaaaand suddenly I can no longer type faster than KRunner can process. Nice finding! +1

broulik accepted this revision.Mar 9 2016, 9:48 AM
broulik added a reviewer: broulik.
This revision is now accepted and ready to land.Mar 9 2016, 9:48 AM
graesslin closed this revision.Mar 10 2016, 11:24 AM