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 340539 - Hitting Escape should close the document properties window
Hitting Escape should close the document properties window
Status: RESOLVED FIXED
Product: evince
Classification: Core
Component: general
git master
Other Linux
: Normal normal
: ---
Assigned To: Evince Maintainers
Evince Maintainers
Depends on:
Blocks:
 
 
Reported: 2006-05-03 15:32 UTC by Wouter Bolsterlee (uws)
Modified: 2006-05-09 08:18 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Proposed fix. (1.88 KB, patch)
2006-05-07 17:37 UTC, Wouter Bolsterlee (uws)
accepted-commit_now Details | Review

Description Wouter Bolsterlee (uws) 2006-05-03 15:32:10 UTC
The summary says it all.
Comment 1 Martin Kretzschmar 2006-05-03 17:11:01 UTC
Just for the record: Esc closes only dialogs that have a Cancel button (and the properties window has only a Close button) (see here for a recent thread where this came up: http://mail.gnome.org/archives/usability/2005-December/msg00032.html where it's also pointed out, that SUSE patches this behavior, and some applications override it as well)

Being in lazy backseat coder mode, I won't take a side here ;-)
Comment 2 Wouter Bolsterlee (uws) 2006-05-03 19:38:45 UTC
Since the Properties dialog has no input elements, Close is effectively the same as Cancel. There's no risk of saving/discarding user entered data without the user telling the application to do so (as is the case for input/preferences dialogs).
Comment 3 Christian Persch 2006-05-04 09:41:44 UTC
You'll get your wish since the gtk+ developers have unilaterally decided to screw us all and do away with the HIG, see bug 101293 :(
Comment 4 Wouter Bolsterlee (uws) 2006-05-07 17:23:03 UTC
That means there is no patch needed and this bug can be closed, since gtk+ handles this.
Comment 5 Wouter Bolsterlee (uws) 2006-05-07 17:34:09 UTC
Reopening, since this only happens for GTK+ 2.9 and up. I will attach a patch that changes the response to GTK_RESPONSE_CANCEL, so that this works for older gtk+ versions too.
Comment 6 Wouter Bolsterlee (uws) 2006-05-07 17:37:11 UTC
Created attachment 64964 [details] [review]
Proposed fix.

Change the properties dialog response to
GTK_RESPONSE_CANCEL instead of GTK_RESPONSE_CLOSE. This
will make the dialog go away when the user presses
enter. With gtk+ >= 2.9 this will happen anyway, but
for older gtk+ versions only GTK_RESPONSE_CANCEL is
bound to escape by default. Fixes bug #340539. See
also bug #101293 for the gtk+ part.
Comment 7 Wouter Bolsterlee (uws) 2006-05-07 17:37:57 UTC
Nickolay, let me know if I can commit this.
Comment 8 Nickolay V. Shmyrev 2006-05-09 03:30:16 UTC
GTK_RESPONSE_CANCEL is better than RESPONSE_ACCEPT anyhow, so please commit this patch without comment (I don't think it's a good thing to leave such references in the code, that's what CVS is used for).
Comment 9 Wouter Bolsterlee (uws) 2006-05-09 08:18:09 UTC
Fixed in the development version. The fix will be available in the next major release. Thank you for your bug report.