[kcmkwin/kwindesktop] Fix global shortcut's display name for kwin changing
ClosedPublic

Authored by davidedmundson on Oct 24 2018, 10:51 PM.

Details

Summary

KGlobalAcceld stores actions grouped by ID and a single display name.
When an action with a given id changes, the display names change for all actions in that
group.

The KCM sets the ID to "kwin" but does not explicitly set a display
name. This means it is automatically deduced which will be kcmshell or
systemsettings.

The end result is all kwin shortcuts get renamed in system setting's
global shortcuts UI until kwin is restarted.

This patch explicitly sets the dispay name.

BUG: 400248
Fixed-in: 5.15.0

Test Plan

Changed virtual desktops
Checked global shortcut settings still listed kwin as kwin

Diff Detail

Repository
R108 KWin
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
Restricted Application added a project: KWin. · View Herald TranscriptOct 24 2018, 10:51 PM
Restricted Application added a subscriber: kwin. · View Herald Transcript
davidedmundson requested review of this revision.Oct 24 2018, 10:51 PM
graesslin accepted this revision.Oct 25 2018, 3:55 AM
graesslin added a subscriber: graesslin.

That bug must be ancient and might be present in many more KWin kcms. E.g tabbox allows to change shortcuts and most effects as well.

This revision is now accepted and ready to land.Oct 25 2018, 3:55 AM
davidedmundson edited the summary of this revision. (Show Details)Oct 25 2018, 10:52 AM

tabbox has this issue. I've added the same change there.

The rest don't use an action collection so seem to be ok.

tabbox has this issue. I've added the same change there.

The rest don't use an action collection so seem to be ok.

the effects do. I just checked cube_config.cpp and it uses an actioncollection, but also uses setComponentDisplayName. As the effect configs are very similar I hope they are all fine.

This revision was automatically updated to reflect the committed changes.