From aa9a83b64ac38330991168ab799d482960e07437 Mon Sep 17 00:00:00 2001 From: raveit65 Date: Fri, 24 Jun 2016 17:14:26 +0200 Subject: GTK+-3: Use ev_document_misc_get_pointer_position() instad of deprecated gtk_widget_get_pointer() --- shell/ev-sidebar-attachments.c | 5 +++++ shell/ev-sidebar-bookmarks.c | 6 ++++++ 2 files changed, 11 insertions(+) (limited to 'shell') diff --git a/shell/ev-sidebar-attachments.c b/shell/ev-sidebar-attachments.c index 84e6cb38..ddcaccda 100644 --- a/shell/ev-sidebar-attachments.c +++ b/shell/ev-sidebar-attachments.c @@ -32,6 +32,7 @@ #include #include "ev-document-attachments.h" +#include "ev-document-misc.h" #include "ev-jobs.h" #include "ev-job-scheduler.h" #include "ev-file-helpers.h" @@ -263,7 +264,11 @@ ev_sidebar_attachments_popup_menu (GtkWidget *widget) EvSidebarAttachments *ev_attachbar = EV_SIDEBAR_ATTACHMENTS (widget); gint x, y; +#if GTK_CHECK_VERSION(3, 0, 0) + ev_document_misc_get_pointer_position (widget, &x, &y); +#else gtk_widget_get_pointer (widget, &x, &y); +#endif return ev_sidebar_attachments_popup_menu_show (ev_attachbar, x, y); } diff --git a/shell/ev-sidebar-bookmarks.c b/shell/ev-sidebar-bookmarks.c index 1e31fbc6..916985bb 100644 --- a/shell/ev-sidebar-bookmarks.c +++ b/shell/ev-sidebar-bookmarks.c @@ -21,10 +21,12 @@ #include "config.h" #include +#include #include "ev-sidebar-bookmarks.h" #include "ev-document.h" +#include "ev-document-misc.h" #include "ev-sidebar-page.h" #include "ev-utils.h" @@ -378,7 +380,11 @@ ev_sidebar_bookmarks_popup_menu (GtkWidget *widget) EvSidebarBookmarks *sidebar_bookmarks = EV_SIDEBAR_BOOKMARKS (widget); gint x, y; +#if GTK_CHECK_VERSION(3, 0, 0) + ev_document_misc_get_pointer_position (widget, &x, &y); +#else gtk_widget_get_pointer (widget, &x, &y); +#endif return ev_sidebar_bookmarks_popup_menu_show (sidebar_bookmarks, x, y, TRUE); } -- cgit v1.2.1