aboutsummaryrefslogtreecommitdiffstats
path: root/src/window.c
diff options
context:
space:
mode:
authorStefan Monnier2007-10-16 16:28:39 +0000
committerStefan Monnier2007-10-16 16:28:39 +0000
commit9beb8baa1f1b59f8e76df62e95647c39acbac5e7 (patch)
treed01390c83402aff49ddf14e282a9edb9bc983ba3 /src/window.c
parentd3f41ff55563551d241407ef640c9984156f87b8 (diff)
downloademacs-9beb8baa1f1b59f8e76df62e95647c39acbac5e7.tar.gz
emacs-9beb8baa1f1b59f8e76df62e95647c39acbac5e7.zip
* xfns.c (Fx_create_frame, Fx_display_list):
* window.c (window_fixed_size_p, enlarge_window, shrink_window_lowest_first): * macterm.c (init_font_name_table): * macfns.c (Fx_create_frame, Fx_display_list): * lread.c (close_load_descs): * keyboard.c (read_char_x_menu_prompt): * fns.c (Fmember, Fmemql, Fdelete, Fset_char_table_parent): * coding.c (code_convert_region_unwind): Test the type of an object rather than just !NILP before extracting data from it.
Diffstat (limited to 'src/window.c')
-rw-r--r--src/window.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/window.c b/src/window.c
index efdf309121b..1819b2dc024 100644
--- a/src/window.c
+++ b/src/window.c
@@ -2670,12 +2670,12 @@ window_fixed_size_p (w, width_p, check_siblings_p)
2670 { 2670 {
2671 Lisp_Object child; 2671 Lisp_Object child;
2672 2672
2673 for (child = w->prev; !NILP (child); child = XWINDOW (child)->prev) 2673 for (child = w->prev; WINDOWP (child); child = XWINDOW (child)->prev)
2674 if (!window_fixed_size_p (XWINDOW (child), width_p, 0)) 2674 if (!window_fixed_size_p (XWINDOW (child), width_p, 0))
2675 break; 2675 break;
2676 2676
2677 if (NILP (child)) 2677 if (NILP (child))
2678 for (child = w->next; !NILP (child); child = XWINDOW (child)->next) 2678 for (child = w->next; WINDOWP (child); child = XWINDOW (child)->next)
2679 if (!window_fixed_size_p (XWINDOW (child), width_p, 0)) 2679 if (!window_fixed_size_p (XWINDOW (child), width_p, 0))
2680 break; 2680 break;
2681 2681
@@ -4291,10 +4291,10 @@ enlarge_window (window, delta, horiz_flag)
4291 4291
4292 /* Find the total we can get from other siblings without deleting them. */ 4292 /* Find the total we can get from other siblings without deleting them. */
4293 maximum = 0; 4293 maximum = 0;
4294 for (next = p->next; ! NILP (next); next = XWINDOW (next)->next) 4294 for (next = p->next; WINDOWP (next); next = XWINDOW (next)->next)
4295 maximum += (*sizefun) (next) - window_min_size (XWINDOW (next), 4295 maximum += (*sizefun) (next) - window_min_size (XWINDOW (next),
4296 horiz_flag, 0, 0); 4296 horiz_flag, 0, 0);
4297 for (prev = p->prev; ! NILP (prev); prev = XWINDOW (prev)->prev) 4297 for (prev = p->prev; WINDOWP (prev); prev = XWINDOW (prev)->prev)
4298 maximum += (*sizefun) (prev) - window_min_size (XWINDOW (prev), 4298 maximum += (*sizefun) (prev) - window_min_size (XWINDOW (prev),
4299 horiz_flag, 0, 0); 4299 horiz_flag, 0, 0);
4300 4300
@@ -4442,10 +4442,10 @@ enlarge_window (window, delta, horiz_flag)
4442 Lisp_Object s; 4442 Lisp_Object s;
4443 int n = 1; 4443 int n = 1;
4444 4444
4445 for (s = w->next; !NILP (s); s = XWINDOW (s)->next) 4445 for (s = w->next; WINDOWP (s); s = XWINDOW (s)->next)
4446 if (!window_fixed_size_p (XWINDOW (s), horiz_flag, 0)) 4446 if (!window_fixed_size_p (XWINDOW (s), horiz_flag, 0))
4447 ++n; 4447 ++n;
4448 for (s = w->prev; !NILP (s); s = XWINDOW (s)->prev) 4448 for (s = w->prev; WINDOWP (s); s = XWINDOW (s)->prev)
4449 if (!window_fixed_size_p (XWINDOW (s), horiz_flag, 0)) 4449 if (!window_fixed_size_p (XWINDOW (s), horiz_flag, 0))
4450 ++n; 4450 ++n;
4451 4451
@@ -4701,7 +4701,7 @@ shrink_window_lowest_first (w, height)
4701 /* Find the last child. We are taking space from lowest windows 4701 /* Find the last child. We are taking space from lowest windows
4702 first, so we iterate over children from the last child 4702 first, so we iterate over children from the last child
4703 backwards. */ 4703 backwards. */
4704 for (child = w->vchild; !NILP (child); child = XWINDOW (child)->next) 4704 for (child = w->vchild; WINDOWP (child); child = XWINDOW (child)->next)
4705 last_child = child; 4705 last_child = child;
4706 4706
4707 /* Assign new heights. We leave only MIN_SAFE_WINDOW_HEIGHT. */ 4707 /* Assign new heights. We leave only MIN_SAFE_WINDOW_HEIGHT. */