* frame.c (Fmake_terminal_frame): Use store_in_alist to setup
authorDmitry Antipov <dmantipov@yandex.ru>
Wed, 31 Jul 2013 07:45:34 +0000 (11:45 +0400)
committerDmitry Antipov <dmantipov@yandex.ru>
Wed, 31 Jul 2013 07:45:34 +0000 (11:45 +0400)
frame parameters and call to Fmodify_frame_parameters just once.

src/ChangeLog
src/frame.c

index b359b8d..0e3e43c 100644 (file)
@@ -1,3 +1,8 @@
+2013-07-31  Dmitry Antipov  <dmantipov@yandex.ru>
+
+       * frame.c (Fmake_terminal_frame): Use store_in_alist to setup
+       frame parameters and call to Fmodify_frame_parameters just once.
+
 2013-07-31  Dmitry Antipov  <dmantipov@yandex.ru>
 
        * frame.c (make_frame, x_set_frame_parameters): Use bool for boolean.
index c7353bf..9e156f3 100644 (file)
@@ -724,16 +724,13 @@ affects all frames on the same terminal device.  */)
   adjust_glyphs (f);
   calculate_costs (f);
   XSETFRAME (frame, f);
+
+  store_in_alist (&parms, Qtty_type, build_string (t->display_info.tty->type));
+  store_in_alist (&parms, Qtty, 
+                 (t->display_info.tty->name
+                  ? build_string (t->display_info.tty->name)
+                  : Qnil));
   Fmodify_frame_parameters (frame, parms);
-  Fmodify_frame_parameters
-    (frame, list1 (Fcons (Qtty_type,
-                         build_string (t->display_info.tty->type))));
-  if (t->display_info.tty->name != NULL)
-    Fmodify_frame_parameters
-      (frame, list1 (Fcons (Qtty,
-                           build_string (t->display_info.tty->name))));
-  else
-    Fmodify_frame_parameters (frame, list1 (Fcons (Qtty, Qnil)));
 
   /* Make the frame face alist be frame-specific, so that each
      frame could change its face definitions independently.  */