Patch: make Esc work in dialogs
- From: Federico Mena Quintero <federico ximian com>
- To: nautilus-list gnome org
- Subject: Patch: make Esc work in dialogs
- Date: Wed, 10 Dec 2003 21:14:21 -0600
This patch makes the Escape key work in two dialogs where it doesn't.
They used a custom response code for Cancel rather than
GTK_RESPONSE_CANCEL.
This happens due to the insanity in #101293, which is getting
ridiculous, so I'll follow up about it in gtk-devel-list immediately.
Is this OK to commit?
Federico
? nautilus-computer.desktop
? nautilus-home.desktop
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/nautilus/ChangeLog,v
retrieving revision 1.6002
diff -u -r1.6002 ChangeLog
--- ChangeLog 10 Dec 2003 13:12:31 -0000 1.6002
+++ ChangeLog 11 Dec 2003 03:07:11 -0000
@@ -1,3 +1,13 @@
+2003-12-10 Federico Mena Quintero <federico ximian com>
+
+ * src/nautilus-connect-server-dialog.c (response_callback): Use
+ GTK_RESPONSE_CANCEL, not a homegrown RESPONSE_CANCEL. This way we
+ can close the dialog by pressing Escape.
+ (nautilus_connect_server_dialog_init): Likewise.
+
+ * src/nautilus-location-dialog.c (response_callback): Likewise.
+ (nautilus_location_dialog_init): Likewise.
+
2003-12-10 Alexander Larsson <alexl redhat com>
* libnautilus-private/apps_nautilus_preferences.schemas.in:
Index: src/nautilus-connect-server-dialog.c
===================================================================
RCS file: /cvs/gnome/nautilus/src/nautilus-connect-server-dialog.c,v
retrieving revision 1.2
diff -u -r1.2 nautilus-connect-server-dialog.c
--- src/nautilus-connect-server-dialog.c 19 Nov 2003 10:50:39 -0000 1.2
+++ src/nautilus-connect-server-dialog.c 11 Dec 2003 03:07:12 -0000
@@ -46,8 +46,7 @@
nautilus_connect_server_dialog,
GTK_TYPE_DIALOG)
enum {
- RESPONSE_CONNECT,
- RESPONSE_CANCEL
+ RESPONSE_CONNECT
};
static void
@@ -132,7 +131,7 @@
break;
case GTK_RESPONSE_NONE:
case GTK_RESPONSE_DELETE_EVENT:
- case RESPONSE_CANCEL:
+ case GTK_RESPONSE_CANCEL:
gtk_widget_destroy (GTK_WIDGET (dialog));
break;
default :
@@ -223,7 +222,7 @@
gtk_dialog_add_button (GTK_DIALOG (dialog),
GTK_STOCK_CANCEL,
- RESPONSE_CANCEL);
+ GTK_RESPONSE_CANCEL);
gtk_dialog_add_button (GTK_DIALOG (dialog),
_("Connect"),
RESPONSE_CONNECT);
Index: src/nautilus-location-dialog.c
===================================================================
RCS file: /cvs/gnome/nautilus/src/nautilus-location-dialog.c,v
retrieving revision 1.1
diff -u -r1.1 nautilus-location-dialog.c
--- src/nautilus-location-dialog.c 11 Oct 2003 17:26:39 -0000 1.1
+++ src/nautilus-location-dialog.c 11 Dec 2003 03:07:12 -0000
@@ -43,8 +43,7 @@
nautilus_location_dialog,
GTK_TYPE_DIALOG)
enum {
- RESPONSE_OPEN,
- RESPONSE_CANCEL
+ RESPONSE_OPEN
};
static void
@@ -96,7 +95,7 @@
break;
case GTK_RESPONSE_NONE :
case GTK_RESPONSE_DELETE_EVENT :
- case RESPONSE_CANCEL :
+ case GTK_RESPONSE_CANCEL :
gtk_widget_destroy (GTK_WIDGET (dialog));
break;
default :
@@ -162,7 +161,7 @@
gtk_dialog_add_button (GTK_DIALOG (dialog),
GTK_STOCK_CANCEL,
- RESPONSE_CANCEL);
+ GTK_RESPONSE_CANCEL);
gtk_dialog_add_button (GTK_DIALOG (dialog),
GTK_STOCK_OPEN,
RESPONSE_OPEN);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]