Save disabling of desktop file components in kglobalshortcutsrc
Needs RevisionPublic

Authored by davidre on Apr 15 2020, 3:02 PM.

Details

Summary

Works for writable and not writable files. Additional positive we don't have to modify the desktop file
That means a kcm doesn't need to do anything special as the component is enabled again automagically upon doRegister().

Diff Detail

Repository
R268 KGlobalAccel
Branch
disable (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 25281
Build 25299: arc lint + arc unit
davidre created this revision.Apr 15 2020, 3:02 PM
Restricted Application added a project: Frameworks. · View Herald TranscriptApr 15 2020, 3:02 PM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
davidre requested review of this revision.Apr 15 2020, 3:02 PM
fvogt requested changes to this revision.Apr 15 2020, 3:20 PM
fvogt added inline comments.
src/runtime/globalshortcutsregistry.cpp
271

disabledComponents is the group name, right? It would also be part of groupList, so it would try to load it as shortcut...

330

Is desktopFile the equivalent to component->uniqueName()? I would assume no, so this check might need to be moved after the KServiceActionComponent construction

This revision now requires changes to proceed.Apr 15 2020, 3:20 PM
davidre added inline comments.Apr 15 2020, 3:22 PM
src/runtime/globalshortcutsregistry.cpp
271

good point

330

It actually is if you follow the constructor chain

davidre updated this revision to Diff 80265.Apr 16 2020, 8:46 AM

Don't parse the disabledGroup as component

davidre marked 4 inline comments as done.Apr 16 2020, 8:46 AM
meven requested changes to this revision.Apr 21 2020, 1:21 PM

Just two qDebug to remove, seems fine otherwise

src/runtime/globalshortcutsregistry.cpp
95

To remove

98

To remove

This revision now requires changes to proceed.Apr 21 2020, 1:21 PM