changeset 9948:982820033564

(x_window_to_frame, x_any_window_to_frame, x_top_window_to_frame): Use the new type-test macros.
author Karl Heuer <kwzh@gnu.org>
date Tue, 15 Nov 1994 23:52:43 +0000
parents 84efab2ce30b
children e9d341f235ee
files src/xfns.c
diffstat 1 files changed, 7 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/src/xfns.c	Tue Nov 15 23:38:26 1994 +0000
+++ b/src/xfns.c	Tue Nov 15 23:52:43 1994 +0000
@@ -260,7 +260,7 @@
 /* Return the Emacs frame-object corresponding to an X window.
    It could be the frame's main window or an icon window.  */
 
-/* This function can be called during GC, so use XGCTYPE.  */
+/* This function can be called during GC, so use GC_xxx type test macros.  */
 
 struct frame *
 x_window_to_frame (wdesc)
@@ -269,11 +269,10 @@
   Lisp_Object tail, frame;
   struct frame *f;
 
-  for (tail = Vframe_list; XGCTYPE (tail) == Lisp_Cons;
-       tail = XCONS (tail)->cdr)
+  for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr)
     {
       frame = XCONS (tail)->car;
-      if (XGCTYPE (frame) != Lisp_Frame)
+      if (!GC_FRAMEP (frame))
         continue;
       f = XFRAME (frame);
 #ifdef USE_X_TOOLKIT
@@ -304,11 +303,10 @@
   struct frame *f;
   struct x_display *x;
 
-  for (tail = Vframe_list; XGCTYPE (tail) == Lisp_Cons;
-       tail = XCONS (tail)->cdr)
+  for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr)
     {
       frame = XCONS (tail)->car;
-      if (XGCTYPE (frame) != Lisp_Frame)
+      if (!GC_FRAMEP (frame))
         continue;
       f = XFRAME (frame);
       if (f->display.nothing == 1) 
@@ -337,11 +335,10 @@
   struct frame *f;
   struct x_display *x;
 
-  for (tail = Vframe_list; XGCTYPE (tail) == Lisp_Cons;
-       tail = XCONS (tail)->cdr)
+  for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr)
     {
       frame = XCONS (tail)->car;
-      if (XGCTYPE (frame) != Lisp_Frame)
+      if (!GC_FRAMEP (frame))
         continue;
       f = XFRAME (frame);
       if (f->display.nothing == 1)