eog r4509 - in branches/gnome-2-22: . src



Author: csaavedra
Date: Wed Apr  2 22:35:29 2008
New Revision: 4509
URL: http://svn.gnome.org/viewvc/eog?rev=4509&view=rev

Log:
2008-04-02  Claudio Saavedra  <csaavedra gnome org>

	* src/eog-window.c: (eog_window_key_press): Give the scrollview
	a chance to handle the key press event, to allow zooming in/out
	if the image doesn't have the focus. Fixes bug #427053.



Modified:
   branches/gnome-2-22/ChangeLog
   branches/gnome-2-22/src/eog-window.c

Modified: branches/gnome-2-22/src/eog-window.c
==============================================================================
--- branches/gnome-2-22/src/eog-window.c	(original)
+++ branches/gnome-2-22/src/eog-window.c	Wed Apr  2 22:35:29 2008
@@ -4485,6 +4485,13 @@
 					   (GdkEvent *) event);
 	}
 
+	/* If the focus is not in the toolbar and we still haven't handled the
+	   event, give the scrollview a chance to do it.  */
+	if ((tbcontainer->focus_child == NULL) && result == FALSE) {
+		result = gtk_widget_event (GTK_WIDGET (EOG_WINDOW (widget)->priv->view),
+					   (GdkEvent *) event);
+	}
+
 	if (result == FALSE && GTK_WIDGET_CLASS (eog_window_parent_class)->key_press_event) {
 		result = (* GTK_WIDGET_CLASS (eog_window_parent_class)->key_press_event) (widget, event);
 	}



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