From: Jan Djärv Date: Thu, 10 Mar 2005 18:07:37 +0000 (+0000) Subject: * gtkutil.c (xg_update_scrollbar_pos): Call x_sync so that the X-Git-Tag: ttn-vms-21-2-B4~1847 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=817d354baa9fcff63f7fcb82cb35b3233b468b64;p=emacs.git * gtkutil.c (xg_update_scrollbar_pos): Call x_sync so that the GTK main loop is entered in xterm.c, thus doing the redraw. --- diff --git a/src/ChangeLog b/src/ChangeLog index f2bef4273ee..e116cdf1d06 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2005-03-10 Jan Dj,Ad(Brv + + * gtkutil.c (xg_update_scrollbar_pos): Call x_sync so that the + GTK main loop is entered in xterm.c, thus doing the redraw. + 2005-03-10 Kim F. Storm * xdisp.c (pos_visible_p): Fix X value in last line of buffer. diff --git a/src/gtkutil.c b/src/gtkutil.c index 6dcba3036c0..8bd83e40043 100644 --- a/src/gtkutil.c +++ b/src/gtkutil.c @@ -2999,9 +2999,14 @@ xg_update_scrollbar_pos (f, scrollbar_id, top, left, width, height) GtkWidget *wparent = gtk_widget_get_parent (wscroll); /* Move and resize to new values. */ - gtk_widget_set_size_request (wscroll, width, height); gtk_fixed_move (GTK_FIXED (wfixed), wparent, left, top); - + gtk_widget_set_size_request (wscroll, width, height); + gtk_widget_queue_draw (wparent); + gdk_window_process_all_updates (); + /* GTK does not redraw until the main loop is entered again, but + if there are no X events pending we will not enter it. So we sync + here to get some events. */ + x_sync (f); SET_FRAME_GARBAGED (f); cancel_mouse_face (f); }