Bug 407721 - Brightness keys no longer work with Plasma 5.16
Summary: Brightness keys no longer work with Plasma 5.16
Status: RESOLVED FIXED
Alias: None
Product: Powerdevil
Classification: Plasma
Component: general (show other bugs)
Version: 5.15.90
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Bhushan Shah
URL:
Keywords:
: 407710 408158 (view as bug list)
Depends on:
Blocks:
 
Reported: 2019-05-19 11:42 UTC by Ilya Bizyaev
Modified: 2019-06-05 06:27 UTC (History)
10 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ilya Bizyaev 2019-05-19 11:42:49 UTC
SUMMARY
I am still able to use the slider in the Battery & Brightness plasmoid, though.

STEPS TO REPRODUCE
1. Press brightness management keys on your keyboard

OBSERVED RESULT
Nothing happens

EXPECTED RESULT
Brightness is adjusted

SOFTWARE/OS VERSIONS
KDE Plasma Version: 5.15.90
KDE Frameworks Version: 5.58
Qt Version: 5.12.3

ADDITIONAL INFORMATION
I use X11, and key events are correctly displayed in libinput-debug-events as KEY_BRIGHTNESSDOWN/KEY_BRIGHTNESSUP.
Comment 1 Rajeesh K V 2019-05-19 12:48:57 UTC
Observed the issue with brightness up/down keys not working in Plasma 5.16 beta. Checking further, System Settings → Shortcuts → Global Shortcuts → Power Management shows that there are two entries each for Decrease and Increase Brightness of Screen/Keyboard, of which one has the correct shortcut assigned. Removing the shortcut from currently assigned entry and assigning it to the second one makes shortcut work again.
Comment 2 Romain D. 2019-05-19 12:57:42 UTC
Observing shortcuts not working (among other things) as the result of kded5 crashing on 5.15.90: https://invent.kde.org/snippets/215
Comment 4 Antonio Rojas 2019-05-19 14:49:21 UTC
After that commit, the settings under the [org_kde_powerdevil] section in ~/.config/kglobalshortcutsrc no longer have effect. Reassigning the shortcuts in systemsettings makes them appear under a new [powerdevil] section, and they work again. This should be done automatically with kconf_update
Comment 5 Richard Ullger 2019-05-20 11:29:26 UTC
Brightness keys are working for me but there is no brightness level pop-up. I have not reassigned the shortcuts.

~/.config/kglobalshortcutsrc contains...

[$Version]
update_info=powerdevil_move_shortcuts.upd:powerdevil_move_shortcuts

[org_kde_powerdevil]
Decrease Keyboard Brightness=Keyboard Brightness Down,Keyboard Brightness Down,Decrease Keyboard Brightness
Decrease Screen Brightness=Monitor Brightness Down,Monitor Brightness Down,Decrease Screen Brightness

[powerdevil]
Decrease Keyboard Brightness=,Keyboard Brightness Down,Decrease Keyboard Brightness
Decrease Screen Brightness=,Monitor Brightness Down,Decrease Screen Brightness



Arch Linux
kde_unstable repo (fix for bug 407614 has been applied)
plasma 5.15.90
qt 5.13.0beta3
Comment 6 Bhushan Shah 2019-05-20 12:31:46 UTC
https://phabricator.kde.org/D21303 modifies the regression introducing code. Unfortunately kconf_update script is not useful for migrating shortcuts.
Comment 7 Bhushan Shah 2019-05-20 12:43:11 UTC
Git commit 90839c802ebc30c1fd46b54bc04a75fe1e7c3a47 by Bhushan Shah.
Committed on 20/05/2019 at 12:35.
Pushed by bshah into branch 'Plasma/5.16'.

Set application name to org_kde_powerdevil

Summary:
Previously application component name without any KAboutData was
org_kde_powerdevil (executable name), although, 972eb26d0558d commit
changed the component name to powerdevil, which had side-effects that
powerdevil would write shortcuts to powerdevil component and it would
conflict with old org_kde_powerdevil shortcuts, and ultimately none
would work.

In theory we can do migration of the shortcuts to powerdevil component
using kconf_update but that doesn't work, as kglobalaccel is already
started before powerdevil, resulting in kconf_update changes having no
effect, more on this in commit 4ae36ddddae which introduces the
PowerDevilApp::migratePre512KeyboardShortcuts() function, while in
theory PowerDevilApp::migratePre516KeyboardShortcuts can be introduced,
we can simply avoid this hassle by re-assigning old component name.

Reviewers: davidedmundson, romangg

Reviewed By: davidedmundson

Subscribers: fvogt, arojas, plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D21303

M  +2    -1    daemon/powerdevilapp.cpp

https://commits.kde.org/powerdevil/90839c802ebc30c1fd46b54bc04a75fe1e7c3a47
Comment 8 Bhushan Shah 2019-05-20 12:49:20 UTC
Commit above will fix it for other users, unfortunately for beta testers, they will still have broken "powerdevil" entry, which will conflict with the org_kde_powerdevil.

Beta testers will need to cleanup the "[powerdevil]" section in ~/.config/kglobalshortcutsrc
Comment 9 Antonio Rojas 2019-05-20 15:30:56 UTC
*** Bug 407710 has been marked as a duplicate of this bug. ***
Comment 10 Antonio Rojas 2019-05-31 19:56:44 UTC
*** Bug 408158 has been marked as a duplicate of this bug. ***
Comment 11 Roman Gilg 2019-06-05 06:27:20 UTC
Thanks Bhushan! Also for the tip with cleaning up the [powerdevil] section. Now also all the duplicated shortcut entries are gone in the Shortcuts KCM for power management.