aboutsummaryrefslogtreecommitdiffstats
path: root/shell/e-shell-view.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2001-04-18 02:35:37 +0800
committerChris Lahey <clahey@src.gnome.org>2001-04-18 02:35:37 +0800
commitccd69a31fd5a84dd24758a37a196dea33f46feea (patch)
treeaec3b064e487159bb334bac594f1a54b9f41fc13 /shell/e-shell-view.c
parente87c3d5baaae937e0131095ae70ea8375c9b039c (diff)
downloadgsoc2013-evolution-ccd69a31fd5a84dd24758a37a196dea33f46feea.tar.gz
gsoc2013-evolution-ccd69a31fd5a84dd24758a37a196dea33f46feea.tar.zst
gsoc2013-evolution-ccd69a31fd5a84dd24758a37a196dea33f46feea.zip
Proxy events to the tooltip object properly.
2001-04-17 Christopher James Lahey <clahey@ximian.com> * e-shell-view.c (storage_set_view_box_event_cb): Proxy events to the tooltip object properly. svn path=/trunk/; revision=9428
Diffstat (limited to 'shell/e-shell-view.c')
-rw-r--r--shell/e-shell-view.c50
1 files changed, 50 insertions, 0 deletions
diff --git a/shell/e-shell-view.c b/shell/e-shell-view.c
index 5615142c2e..bc8dd1531d 100644
--- a/shell/e-shell-view.c
+++ b/shell/e-shell-view.c
@@ -211,6 +211,54 @@ storage_set_view_box_button_release_event_cb (GtkWidget *widget,
return TRUE;
}
+static int
+storage_set_view_box_event_cb (GtkWidget *widget,
+ GdkEvent *event,
+ void *data)
+{
+ GtkWidget *event_widget;
+ GtkWidget *tooltip;
+ EShellView *shell_view;
+ EShellViewPrivate *priv;
+
+ shell_view = E_SHELL_VIEW (data);
+ priv = shell_view->priv;
+
+ event_widget = gtk_get_event_widget (event);
+
+ if (!event_widget)
+ return FALSE;
+
+ tooltip = e_tree_get_tooltip (E_TREE(priv->storage_set_view));
+ if (! (GTK_WIDGET_IS_SENSITIVE (event_widget) &&
+ tooltip &&
+ gtk_widget_is_ancestor (event_widget, tooltip)))
+ return FALSE;
+
+ switch (event->type) {
+ case GDK_BUTTON_PRESS:
+ case GDK_2BUTTON_PRESS:
+ case GDK_3BUTTON_PRESS:
+ case GDK_KEY_PRESS:
+ case GDK_KEY_RELEASE:
+ case GDK_MOTION_NOTIFY:
+ case GDK_BUTTON_RELEASE:
+ case GDK_PROXIMITY_IN:
+ case GDK_PROXIMITY_OUT:
+ gtk_propagate_event (event_widget, event);
+ return TRUE;
+ break;
+ case GDK_ENTER_NOTIFY:
+ case GDK_LEAVE_NOTIFY:
+ gtk_widget_event (event_widget, event);
+ return TRUE;
+ break;
+ default:
+ break;
+ }
+ return FALSE;
+}
+
static void
popup_storage_set_view_button_clicked (ETitleBar *title_bar,
void *data)
@@ -253,6 +301,8 @@ storage_set_view_box_map_cb (GtkWidget *widget,
}
gtk_grab_add (widget);
+ gtk_signal_connect (GTK_OBJECT (widget), "event",
+ GTK_SIGNAL_FUNC (storage_set_view_box_event_cb), shell_view);
gtk_signal_connect (GTK_OBJECT (widget), "button_release_event",
GTK_SIGNAL_FUNC (storage_set_view_box_button_release_event_cb), shell_view);
gtk_signal_connect (GTK_OBJECT (priv->storage_set_view), "button_release_event",