From 372132a61963d09acd22a4c039fa235094beb233 Mon Sep 17 00:00:00 2001 From: Guilhem Bonnefille Date: Sat, 15 Mar 2008 09:15:44 +0000 Subject: [PATCH] Fix: [ 1839948 ] Maximize/Restore changes current cursor This fix is quite gruik as I think there is a good way to synchronize tools and their cursors. I commited it as is because I plan to refactor this part. --- ChangeLog | 4 ++++ src/vikwindow.c | 8 +++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 3a217537..83c5cfd9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-03-15: +Guilhem Bonnefille : + * Fix: [ 1839948 ] Maximize/Restore changes current cursor + 2008-02-25: Guilhem Bonnefille : * po/ChangeLog: needed file for distribution diff --git a/src/vikwindow.c b/src/vikwindow.c index 8486a643..13ae5c83 100644 --- a/src/vikwindow.c +++ b/src/vikwindow.c @@ -407,8 +407,14 @@ void vik_window_set_redraw_trigger(VikLayer *vl) static void window_configure_event ( VikWindow *vw ) { + static first = 1; draw_redraw ( vw ); - gdk_window_set_cursor ( GTK_WIDGET(vw->viking_vvp)->window, vw_cursor_zoom ); + if (first) { + // This is a hack to set the cursor corresponding to the first tool + // FIXME find the correct way to initialize both tool and its cursor + first = 0; + gdk_window_set_cursor ( GTK_WIDGET(vw->viking_vvp)->window, vw_cursor_zoom ); + } } static void draw_redraw ( VikWindow *vw ) -- 2.11.4.GIT