After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 739647 - Custom shortcut dialog should require name and command
Custom shortcut dialog should require name and command
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: Keyboard
unspecified
Other All
: Normal normal
: ---
Assigned To: Rui Matos
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-11-04 21:41 UTC by Marcus Karlsson
Modified: 2015-02-10 12:52 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
keyboard: custom shortcut should require name and command (4.67 KB, patch)
2014-11-04 21:48 UTC, Marcus Karlsson
committed Details | Review

Description Marcus Karlsson 2014-11-04 21:41:24 UTC
Summary:

The custom shortcut dialog in gnome-control-center allows that the name field and the command field is empty. This can produce confusing results.

Steps to reproduce:

1. Go to the Keyboard panel.
2. Select the Shortcuts tab.
3. Press the plus (+) button to add a new custom shortcut.
4. Press the Add button in the Custom Shortcuts dialog without entering anything in the name field or in the command field.

Expected result:

The Add button is disabled until both the name and the command is filled in.

Actual result:

The dialog disappears and no shortcut is created. Also, if an existing shortcut is edited and the command field is empty then the shortcut is removed.

Notes:

It should only be possible to add a shortcut or edit an existing shortcut if both the name field and the command field is filled in. Especially, the shortcut should not be removed if the command field is empty; there is a button specifically for removing shortcuts.
Comment 1 Marcus Karlsson 2014-11-04 21:48:57 UTC
Created attachment 289994 [details] [review]
keyboard: custom shortcut should require name and command

This patch disables the Add button, it is only enabled when the name and command is non-empty.
Comment 2 Bastien Nocera 2014-11-05 15:32:52 UTC
Review of attachment 289994 [details] [review]:

Looks fine.
Comment 3 Bastien Nocera 2015-02-10 12:52:03 UTC
Attachment 289994 [details] pushed as fe9fe99 - keyboard: custom shortcut should require name and command