This is an automatically generated e-mail. To reply, visit:

Review request for Plasma.

Bugs: 367685

Repository: plasma-framework


# The new Meta-key support for launcher opening doesn't work for closing at the 
moment. My analysis of the problem was as follows:

- KWin calls Applet::activated() over DBus
- Applet::activated() is connected to AppletInterface::activated()
- AppletInterface::activated() is connected to setExpanded(true), which can 
only expand the launcher, but not the other way around

# Q: Why is Alt+F1 working though?
A: The launchers seem to inherit the reimplementation function 
Dialog::focusOutEvent(..). Atleast when you delete line 1094, which sets the 
visibility to false, it's not working anymore. Alt+F1 triggers the 
focusOutEvent(..) as a global shortcut.

# Q: Why is it working with the Dashboard though?
A: The dashboard doesn't use the expanded feature of the plasmoid, but rather 
connects directly to the AppletInterface::activated() signal and shows/hides an 
independent widget by getting triggered on it.

# Solution:
Create new toggled() signal chain in KWin, Applet, AppletInterface, which tests 
the current expanded state and setting it afterwards accordingly to its 
opposite. This diff here in plasma-framework is the first one, the others are 
dependent on. The others are on Phabricator:

- kwin: soon
- plasma-workspace: soon
- plasma-desktop: soon

# Need feedback regarding:

- Should we remove the activated() signal chain? Is it used somewhere else than 
- Could a race condition occur if we deexpand the applet while at the same time 
setting the visibility to false through focusOutEvent()? My tests until now 
don't suggest it, but I haven't yet looked into it extensively.


  src/plasma/applet.h 89498ea 
  src/scriptengines/qml/plasmoid/appletinterface.h a1e2cd7 
  src/scriptengines/qml/plasmoid/appletinterface.cpp 1cd6934 

Diff: https://git.reviewboard.kde.org/r/129204/diff/



Roman Gilg

Reply via email to