emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs/src ChangeLog dispnew.c term.c


From: Dan Nicolaescu
Subject: [Emacs-diffs] emacs/src ChangeLog dispnew.c term.c
Date: Fri, 30 Jan 2009 23:45:29 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Changes by:     Dan Nicolaescu <dann>   09/01/30 23:45:29

Modified files:
        src            : ChangeLog dispnew.c term.c 

Log message:
        * dispnew.c (window_change_signal): Don't try to get the size of a
        suspended tty frame.
        * term.c (Fresume_tty): Resize if the size has changed while the
        tty was suspended.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/src/ChangeLog?cvsroot=emacs&r1=1.7331&r2=1.7332
http://cvs.savannah.gnu.org/viewcvs/emacs/src/dispnew.c?cvsroot=emacs&r1=1.426&r2=1.427
http://cvs.savannah.gnu.org/viewcvs/emacs/src/term.c?cvsroot=emacs&r1=1.234&r2=1.235

Patches:
Index: ChangeLog
===================================================================
RCS file: /cvsroot/emacs/emacs/src/ChangeLog,v
retrieving revision 1.7331
retrieving revision 1.7332
diff -u -b -r1.7331 -r1.7332
--- ChangeLog   30 Jan 2009 23:43:20 -0000      1.7331
+++ ChangeLog   30 Jan 2009 23:45:27 -0000      1.7332
@@ -1,5 +1,10 @@
 2009-01-30  Dan Nicolaescu  <address@hidden>
 
+       * dispnew.c (window_change_signal): Don't try to get the size of a
+       suspended tty frame.
+       * term.c (Fresume_tty): Resize if the size has changed while the
+       tty was suspended.
+
        * alloc.c (mark_stack): Properly conditionalize previous change.
 
 2009-01-30  Juanma Barranquero  <address@hidden>

Index: dispnew.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/dispnew.c,v
retrieving revision 1.426
retrieving revision 1.427
diff -u -b -r1.426 -r1.427
--- dispnew.c   25 Jan 2009 17:00:55 -0000      1.426
+++ dispnew.c   30 Jan 2009 23:45:29 -0000      1.427
@@ -6218,6 +6218,11 @@
     if (! tty->term_initted)
       continue;
 
+    /* Suspended tty frames have tty->input == NULL avoid trying to
+       use it.  */
+    if (!tty->input)
+      continue;
+
     get_tty_size (fileno (tty->input), &width, &height);
 
     if (width > 5 && height > 2) {

Index: term.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/term.c,v
retrieving revision 1.234
retrieving revision 1.235
diff -u -b -r1.234 -r1.235
--- term.c      8 Jan 2009 03:15:58 -0000       1.234
+++ term.c      30 Jan 2009 23:45:29 -0000      1.235
@@ -2470,7 +2470,19 @@
 #endif
 
       if (FRAMEP (t->display_info.tty->top_frame))
+       {
+         struct frame *f = XFRAME (t->display_info.tty->top_frame);
+         int width, height;
+         int old_height = FRAME_COLS (f);
+         int old_width = FRAME_LINES (f);
+
+         /* Check if terminal/window size has changed while the frame
+            was suspended.  */
+         get_tty_size (fileno (t->display_info.tty->input), &width, &height);
+         if (width != old_width || height != old_height)
+           change_frame_size (f, height, width, 0, 0, 0);
         FRAME_SET_VISIBLE (XFRAME (t->display_info.tty->top_frame), 1);
+       }
 
       init_sys_modes (t->display_info.tty);
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]