]> code.delx.au - gnu-emacs/commitdiff
(init_tty) [WINDOWSNT]: Add hooks that are not accessible
authorJason Rumney <jasonr@gnu.org>
Tue, 4 Sep 2007 23:14:37 +0000 (23:14 +0000)
committerJason Rumney <jasonr@gnu.org>
Tue, 4 Sep 2007 23:14:37 +0000 (23:14 +0000)
in w32console.c.  Set up input.  Remove XXX comments that have been
confirmed as correct.

src/ChangeLog
src/term.c

index 0a5885d516c8bfdb751edc9324414a9da840e4cd..2533d5f0c6ce6713ebcfde0f5fe10d2d46adeaa7 100644 (file)
@@ -1,5 +1,9 @@
 2007-09-04  Jason Rumney  <jasonr@gnu.org>
 
+       * term.c (init_tty) [WINDOWSNT]: Add hooks that are not accessible
+       in w32console.c.  Set up input.  Remove XXX comments that have been
+       confirmed as correct.
+
        * s/ms-w32.h (MULTI_KBOARD): Define.
 
        * w32console.c (one_and_only_w32cons): Remove.
index 9d659edaa5fcaab00cde88ecb9fb343b4f753fd6..d8bf5647e2d4f69d23d505b3bf0d20a9b19b233e 100644 (file)
@@ -3273,6 +3273,9 @@ init_tty (char *name, char *terminal_type, int must_succeed)
 
 #ifdef WINDOWSNT
   initialize_w32_display (terminal);
+  /* The following two are inaccessible from w32console.c.  */
+  terminal->delete_frame_hook = &delete_tty_output;
+  terminal->delete_terminal_hook = &delete_tty;
 
   /* XXX Can this be non-null?  */
   if (name)
@@ -3282,23 +3285,21 @@ init_tty (char *name, char *terminal_type, int must_succeed)
     }
   tty->type = xstrdup (terminal_type);  
 
-  /* XXX not sure if this line is correct. If it is not set then we
-     crash in update_display_1. */
   tty->output = stdout;
-  
-  Wcm_clear (tty);
+  tty->input = stdin;
+  add_keyboard_wait_descriptor (0);
 
-  area = (char *) xmalloc (2044); /* XXX this seems unused. */
+  Wcm_clear (tty);
 
   {
     struct frame *f = XFRAME (selected_frame);
 
-    FrameRows (tty) = FRAME_LINES (f); /* XXX */
-    FrameCols (tty) = FRAME_COLS (f);  /* XXX */
-    tty->specified_window = FRAME_LINES (f); /* XXX */
+    FrameRows (tty) = FRAME_LINES (f);
+    FrameCols (tty) = FRAME_COLS (f);
+    tty->specified_window = FRAME_LINES (f);
 
-    FRAME_CAN_HAVE_SCROLL_BARS (f) = 0; /* XXX */
-    FRAME_VERTICAL_SCROLL_BAR_TYPE (f) = vertical_scroll_bar_none; /* XXX */
+    FRAME_CAN_HAVE_SCROLL_BARS (f) = 0;
+    FRAME_VERTICAL_SCROLL_BAR_TYPE (f) = vertical_scroll_bar_none;
   }
   tty->delete_in_insert_mode = 1;