GNOME Bugzilla – Bug 746980
media-keys: invert in_lock_screen logic and give it a better name
Last modified: 2015-04-01 21:15:06 UTC
Commit 8d417087fce83 inverted the logic in do_action(). In my case it broke the interactive menu when pressing the power key. Follow power_action() naming convention for the parameter name.
Created attachment 300546 [details] [review] media-keys: invert in_lock_screen logic and give it a better name
Review of attachment 300546 [details] [review]: Sure, well spotted!
Review of attachment 300546 [details] [review]: Actually, this code already existed in 3.14 (and probably earlier). I'll rework the patch.
Created attachment 300729 [details] [review] media-keys: Fix logic error when handling power keys In the lock screen, means non-interactive action: in_lock_screen == !power_action_interactive Rename the variable to avoid having to invert it twice. Spotted by Clément Guérin <geecko.dev@free.fr>
Attachment 300729 [details] pushed as a733ec3 - media-keys: Fix logic error when handling power keys
I'm not sure if your approach is better, anyway, thanks for merging it! :)
(In reply to Clément Guérin from comment #6) > I'm not sure if your approach is better, anyway, thanks for merging it! :) It avoids changes to do_power_action() which means we can cherry-pick, and it's not that much uglier ;)