[evince/wip/gpoo/gtk4-rebase-port: 63/96] ev-view: move to name based cursor API
- From: Germán Poo-Caamaño <gpoo src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evince/wip/gpoo/gtk4-rebase-port: 63/96] ev-view: move to name based cursor API
- Date: Sun, 20 Mar 2022 21:50:30 +0000 (UTC)
commit 14356d342f699b2fb39de32b2b785ebe0fb925b8
Author: Qiu Wenbo <qiuwenbo kylinos com cn>
Date: Wed Dec 8 11:18:15 2021 +0800
ev-view: move to name based cursor API
Signed-off-by: Qiu Wenbo <qiuwenbo kylinos com cn>
libview/ev-view.c | 9 ++-------
1 file changed, 2 insertions(+), 7 deletions(-)
---
diff --git a/libview/ev-view.c b/libview/ev-view.c
index 348aa3d2e..bec31a386 100644
--- a/libview/ev-view.c
+++ b/libview/ev-view.c
@@ -10149,7 +10149,6 @@ ev_view_copy_link_address (EvView *view,
static void
ev_view_set_cursor (EvView *view, EvViewCursor new_cursor)
{
- GdkCursor *cursor = NULL;
GtkWidget *widget;
if (view->cursor == new_cursor) {
@@ -10158,12 +10157,8 @@ ev_view_set_cursor (EvView *view, EvViewCursor new_cursor)
view->cursor = new_cursor;
- widget = GTK_WIDGET (gtk_widget_get_native (GTK_WIDGET (view)));
- cursor = ev_view_cursor_new (new_cursor);
- gtk_widget_set_cursor (widget, cursor);
- gdk_display_flush (gtk_widget_get_display (widget));
- if (cursor)
- g_object_unref (cursor);
+ gtk_widget_set_cursor_from_name (GTK_WIDGET (view),
+ ev_view_cursor_name (new_cursor));
}
void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]