[PATCH] Add Internet Explorer-like keybindings



Sorry, but bug 305252 [1] is nearly unquotable, since it consists of
very very long rants.

The purpose of the patch should be obvious.

[1] http://bugzilla.gnome.org/show_bug.cgi?id=305252


-- 
Christian Neumair <chris gnome-de org>
Index: src/nautilus-window.c
===================================================================
RCS file: /cvs/gnome/nautilus/src/nautilus-window.c,v
retrieving revision 1.446
diff -u -r1.446 nautilus-window.c
--- src/nautilus-window.c	17 May 2005 10:51:28 -0000	1.446
+++ src/nautilus-window.c	24 May 2005 14:39:19 -0000
@@ -103,6 +103,8 @@
 
 enum {
 	GO_UP,
+	RELOAD,
+	PROMPT_FOR_LOCATION,
 	LAST_SIGNAL
 };
 
@@ -1471,11 +1473,32 @@
 			      g_signal_accumulator_true_handled, NULL,
 			      eel_marshal_BOOLEAN__BOOLEAN,
 			      G_TYPE_BOOLEAN, 1, G_TYPE_BOOLEAN);
+	signals[RELOAD] =
+		g_signal_new ("reload",
+			      G_TYPE_FROM_CLASS (class),
+			      G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
+			      G_STRUCT_OFFSET (NautilusWindowClass, reload),
+			      NULL, NULL,
+			      g_cclosure_marshal_VOID__VOID,
+			      G_TYPE_NONE, 0);
+	signals[PROMPT_FOR_LOCATION] =
+		g_signal_new ("prompt-for-location",
+			      G_TYPE_FROM_CLASS (class),
+			      G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
+			      G_STRUCT_OFFSET (NautilusWindowClass, prompt_for_location),
+			      NULL, NULL,
+			      g_cclosure_marshal_VOID__VOID,
+			      G_TYPE_NONE, 0);
 	
 	binding_set = gtk_binding_set_by_class (class);
 	gtk_binding_entry_add_signal (binding_set, GDK_BackSpace, 0,
 				      "go_up", 1,
 				      G_TYPE_BOOLEAN, FALSE);
+	gtk_binding_entry_add_signal (binding_set, GDK_F5, 0,
+				      "reload", 0);
+	gtk_binding_entry_add_signal (binding_set, GDK_F6, 0,
+				      "prompt-for-location", 0);
 
+	class->reload = nautilus_window_reload;
 	class->go_up = nautilus_window_go_up_signal;
 }
Index: src/nautilus-window.h
===================================================================
RCS file: /cvs/gnome/nautilus/src/nautilus-window.h,v
retrieving revision 1.119
diff -u -r1.119 nautilus-window.h
--- src/nautilus-window.h	17 May 2005 10:51:28 -0000	1.119
+++ src/nautilus-window.h	24 May 2005 14:39:19 -0000
@@ -73,6 +73,7 @@
         void   (* set_throbber_active) (NautilusWindow *window,
                                         gboolean active);
 	void   (* set_allow_up) (NautilusWindow *window, gboolean allow);
+	void   (* reload)              (NautilusWindow *window);
         void   (* prompt_for_location) (NautilusWindow *window);
         void   (* get_default_size) (NautilusWindow *window, guint *default_width, guint *default_height);
         void   (* show_window)  (NautilusWindow *window);

Attachment: signature.asc
Description: This is a digitally signed message part



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]