changeset 50316:04ec77031c94

* xdisp.c (update_menu_bar): Set w->update_mode_line to Qt so tool bar gets updated.
author Jan Djärv <jan.h.d@swipnet.se>
date Wed, 26 Mar 2003 16:13:44 +0000
parents c2d003df000c
children e0b9e9b6bfac
files src/ChangeLog src/xdisp.c
diffstat 2 files changed, 11 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Wed Mar 26 15:23:36 2003 +0000
+++ b/src/ChangeLog	Wed Mar 26 16:13:44 2003 +0000
@@ -1,3 +1,8 @@
+2003-03-26  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
+
+	* xdisp.c (update_menu_bar): Set w->update_mode_line to Qt
+	so tool bar gets updated.
+
 2003-03-26  Stefan Monnier  <monnier@cs.yale.edu>
 
 	* data.c (store_symval_forwarding): Re-instate part of the code
--- a/src/xdisp.c	Wed Mar 26 15:23:36 2003 +0000
+++ b/src/xdisp.c	Wed Mar 26 16:13:44 2003 +0000
@@ -7905,11 +7905,16 @@
   window = FRAME_SELECTED_WINDOW (f);
   w = XWINDOW (window);
 
-#if 0 /* The if statement below this if statement used to include the
+#if 1 /* The if statement below this if statement used to include the
          condition !NILP (w->update_mode_line), rather than using
          update_mode_lines directly, and this if statement may have
          been added to make that condition work.  Now the if
          statement below matches its comment, this isn't needed.  */
+  /* We need to set w->update_mode_line to Qt so that update_tool_bar
+     rebuilds tool bar items.  For example, to notice when a tool bar item
+     goes from enabled to disabled state.
+     A better way would be to notice tool bar, menu bar and mode line
+     changes separately, but for now update_mode_line is all we got.  */
   if (update_mode_lines)
     w->update_mode_line = Qt;
 #endif