[Github-comments] [geany] Set close dialog and esc key events as cancel in show_prompt() (#714)

Akronix notifications at xxxxx
Wed Oct 28 11:08:56 UTC 2015


Line dialogs.c:1347 says "/* For a cancel button, use cancel response so user can press escape to cancel */" however in line 1357 only GTK_RESPONSE_CANCEL is linked to response_2, but esc KEY triggers a GTK_RESPONSE_DELETE_EVEN; hence it should be included also in 1357.

I found it because of a strange behaviour when cancelling a keybinding override in preferences dialog. You can reproduce it like so: go to prefs>keybindings, set a keybinding which is already used for another command, then Geany will show up a dialog saying that the combination is already used. Once there, if you press <kbd>Esc</kbd> key, you'll see that it does the "Allow" action, instead of -what the user would expect- the "Cancel" action.

I'm testing it and dialogs work fine as well as the issue exposed above is fixed.
You can view, comment on, or merge this pull request online at:

  https://github.com/geany/geany/pull/714

-- Commit Summary --

  * Set close dialog and esc key events as cancel in show_prompt()

-- File Changes --

    M src/dialogs.c (2)

-- Patch Links --

https://github.com/geany/geany/pull/714.patch
https://github.com/geany/geany/pull/714.diff

---
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/714
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20151028/9ad00c63/attachment.html>


More information about the Github-comments mailing list