wok annotate epdfview/stuff/fix-scrolling.patch @ rev 24334
polkit: CVE-2021-4034
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Jan 28 11:07:11 2022 +0000 (2022-01-28) |
parents | |
children |
rev | line source |
---|---|
slaxemulator@8512 | 1 --- ./src/gtk/MainView.cxx.old 2009-02-28 22:00:55.000000000 +0100 |
slaxemulator@8512 | 2 +++ ./src/gtk/MainView.cxx 2009-03-20 03:12:10.000000000 +0100 |
slaxemulator@8512 | 3 @@ -77,7 +77,7 @@ |
slaxemulator@8512 | 4 static void main_window_zoom_out_cb (GtkWidget *, gpointer); |
slaxemulator@8512 | 5 static void main_window_zoom_width_cb (GtkToggleAction *, gpointer); |
slaxemulator@8512 | 6 static void main_window_set_page_mode (GtkRadioAction *, GtkRadioAction *, gpointer); |
slaxemulator@8512 | 7 -static void main_window_page_scrolled_cb (GtkWidget *widget, GdkEventScroll *event, gpointer data); |
slaxemulator@8512 | 8 +static gboolean main_window_page_scrolled_cb (GtkWidget *widget, GdkEventScroll *event, gpointer data); |
slaxemulator@8512 | 9 |
slaxemulator@8512 | 10 #if defined (HAVE_CUPS) |
slaxemulator@8512 | 11 static void main_window_print_cb (GtkWidget *, gpointer); |
slaxemulator@8512 | 12 @@ -1479,18 +1479,19 @@ |
slaxemulator@8512 | 13 pter->setPageMode (mode); |
slaxemulator@8512 | 14 } |
slaxemulator@8512 | 15 |
slaxemulator@8512 | 16 -void |
slaxemulator@8512 | 17 +gboolean |
slaxemulator@8512 | 18 main_window_page_scrolled_cb (GtkWidget *widget, GdkEventScroll *event, gpointer data) |
slaxemulator@8512 | 19 { |
slaxemulator@8512 | 20 g_assert ( NULL != data && "The data parameter is NULL."); |
slaxemulator@8512 | 21 |
slaxemulator@8512 | 22 MainPter *pter = (MainPter *)data; |
slaxemulator@8512 | 23 // Only zoom when the CTRL-Button is down... |
slaxemulator@8512 | 24 - if ( !(event->state & GDK_CONTROL_MASK) ) return; |
slaxemulator@8512 | 25 + if ( !(event->state & GDK_CONTROL_MASK) ) return FALSE; |
slaxemulator@8512 | 26 if ( event->direction == GDK_SCROLL_UP ) { |
slaxemulator@8512 | 27 pter->zoomInActivated (); |
slaxemulator@8512 | 28 } else if ( event->direction == GDK_SCROLL_DOWN ) { |
slaxemulator@8512 | 29 pter->zoomOutActivated (); |
slaxemulator@8512 | 30 } |
slaxemulator@8512 | 31 + return TRUE; |
slaxemulator@8512 | 32 } |
slaxemulator@8512 | 33 |