From c59b52777a65115caaa7b419ba43d03106f4b914 Mon Sep 17 00:00:00 2001 From: monsta Date: Thu, 9 Jun 2016 12:02:02 +0300 Subject: GTK+3: allow indicators to receive mouse scroll event will be handy for changing volume in indicator-sound with mouse scroll --- src/applet-main.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src') diff --git a/src/applet-main.c b/src/applet-main.c index 385c21a..3c0cc60 100644 --- a/src/applet-main.c +++ b/src/applet-main.c @@ -291,6 +291,11 @@ entry_added (IndicatorObject * io, IndicatorObjectEntry * entry, GtkWidget * men gtk_hbox_new(FALSE, 3) : gtk_vbox_new(FALSE, 3); #endif +#if GTK_CHECK_VERSION (3, 0, 0) + /* Allows indicators to receive mouse scroll event in GTK+3 */ + gtk_widget_add_events(GTK_WIDGET(menuitem), GDK_SCROLL_MASK); +#endif + g_object_set_data (G_OBJECT (menuitem), "indicator", io); g_object_set_data (G_OBJECT (menuitem), "box", box); -- cgit v1.2.1