diff options
author | TingPing <tingping@tingping.se> | 2013-10-08 18:16:10 -0400 |
---|---|---|
committer | TingPing <tingping@tingping.se> | 2013-10-08 18:16:10 -0400 |
commit | 0c3220c4697598badbf222b7b6209326ec863942 (patch) | |
tree | da98c52bf70596e83488a241d5d9b120dcd98869 /src/fe-gtk/chanview-tabs.c | |
parent | e52905f50c7ff5d123a58ba016dcbb9de2b13f4f (diff) |
Add preference to change tabs on scroll
Also revert e52905f50c7ff5d123a58ba016dcbb9de2b13f4f
Diffstat (limited to 'src/fe-gtk/chanview-tabs.c')
-rw-r--r-- | src/fe-gtk/chanview-tabs.c | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/src/fe-gtk/chanview-tabs.c b/src/fe-gtk/chanview-tabs.c index e2e421da..dd1d16b7 100644 --- a/src/fe-gtk/chanview-tabs.c +++ b/src/fe-gtk/chanview-tabs.c @@ -233,11 +233,21 @@ tab_scroll_right_down_clicked (GtkWidget *widget, chanview *cv) static gboolean tab_scroll_cb (GtkWidget *widget, GdkEventScroll *event, gpointer cv) { - /* mouse wheel scrolling */ - if (event->direction == GDK_SCROLL_UP) - tab_scroll_left_up_clicked (widget, cv); - else if (event->direction == GDK_SCROLL_DOWN) - tab_scroll_right_down_clicked (widget, cv); + if (prefs.hex_gui_tab_scrollchans) + { + if (event->direction == GDK_SCROLL_DOWN) + mg_switch_page (1, 1); + else if (event->direction == GDK_SCROLL_UP) + mg_switch_page (1, -1); + } + else + { + /* mouse wheel scrolling */ + if (event->direction == GDK_SCROLL_UP) + tab_scroll_left_up_clicked (widget, cv); + else if (event->direction == GDK_SCROLL_DOWN) + tab_scroll_right_down_clicked (widget, cv); + } return FALSE; } |