Mercurial > hg > xemacs-beta
diff src/window.c @ 215:1f0dabaa0855 r20-4b6
Import from CVS: tag r20-4b6
author | cvs |
---|---|
date | Mon, 13 Aug 2007 10:07:35 +0200 |
parents | 78478c60bfcd |
children | d44af0c54775 |
line wrap: on
line diff
--- a/src/window.c Mon Aug 13 10:06:48 2007 +0200 +++ b/src/window.c Mon Aug 13 10:07:35 2007 +0200 @@ -2926,16 +2926,16 @@ else if (!NILP (major_kid)) { int last_pos, last_old_pos, pos, old_pos, first; + int pixel_adj_left = new_pixsize - old_pixsize; int div_val = old_pixsize << 1; /* * Previously we bailed out here if there was no size change. - * But this broke toolbar updates. If a toolbar appears or - * disappears, windows may not change size, but their top and - * left coordinates need to be updated. + * (pixel_adj_left == 0) But this broke toolbar updates. If a + * toolbar appears or disappears, windows may not change size, + * but their top and left coordinates need to be updated. * - * if (!pixel_adj_left) - * return; + * So we don't bail until after the loop below. */ last_pos = first = (set_height ? WINDOW_TOP (w) : WINDOW_LEFT (w)); @@ -2969,6 +2969,11 @@ last_old_pos = old_pos; } + /* Sometimes we may get called with our old size. In that case + we don't need to do anything else. */ + if (!pixel_adj_left) + return; + /* Now delete any children that became too small. */ if (!nodelete) for (child = major_kid; !NILP (child); child = XWINDOW (child)->next)