From: Eli Zaretskii Date: Fri, 5 Nov 2010 10:03:17 +0000 (+0200) Subject: Cleanup fallout from redesigning mouse highlight. X-Git-Tag: emacs-pretest-24.0.90~104^2~275^2~438^2~45^2~370^2~3 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=28118eb6e58a8461e2deef53b68fea513eaef825;p=emacs.git Cleanup fallout from redesigning mouse highlight. dispextern.h (tty_draw_row_with_mouse_face): Add prototype. xdisp.c (draw_row_with_mouse_face): Don't #ifdef away on MSDOS. Call tty_draw_row_with_mouse_face on MSDOS as well. msdos.c (tty_draw_row_with_mouse_face): Renamed from draw_row_with_mouse_face. Make the argument list identical to the GPM implementation. msdos.h (Display_Info): Restore typedef. --- diff --git a/src/ChangeLog b/src/ChangeLog index 0e9d549e54a..db3582db7bd 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,16 @@ +2010-11-05 Eli Zaretskii + + * dispextern.h (tty_draw_row_with_mouse_face): Add prototype. + + * xdisp.c (draw_row_with_mouse_face): Don't #ifdef away on MSDOS. + Call tty_draw_row_with_mouse_face on MSDOS as well. + + * msdos.c (tty_draw_row_with_mouse_face): Renamed from + draw_row_with_mouse_face. Make the argument list identical with + GPM implementation. + + * msdos.h (Display_Info): Restore typedef. + 2010-11-02 Eli Zaretskii * term.c: Remove static mouse_face_* variables. All users diff --git a/src/dispextern.h b/src/dispextern.h index 37ab2b4c9b6..2ac3918ea98 100644 --- a/src/dispextern.h +++ b/src/dispextern.h @@ -3040,12 +3040,13 @@ extern void frame_to_window_pixel_xy (struct window *, int *, int *); extern void note_mouse_highlight (struct frame *, int, int); extern void x_clear_window_mouse_face (struct window *); extern void cancel_mouse_face (struct frame *); -extern int clear_mouse_face (Display_Info *); -extern void show_mouse_face (Display_Info *, enum draw_glyphs_face); +extern int clear_mouse_face (Mouse_HLInfo *); +extern void show_mouse_face (Mouse_HLInfo *, enum draw_glyphs_face); extern int cursor_in_mouse_face_p (struct window *w); extern void draw_row_with_mouse_face (struct window *, int, struct glyph_row *, int, int, enum draw_glyphs_face); - +extern void tty_draw_row_with_mouse_face (struct window *, struct glyph_row *, + int, int, enum draw_glyphs_face); /* Flags passed to try_window. */ #define TRY_WINDOW_CHECK_MARGINS (1 << 0) diff --git a/src/msdos.c b/src/msdos.c index 9826beb1721..6593714ba1f 100644 --- a/src/msdos.c +++ b/src/msdos.c @@ -948,12 +948,12 @@ popup_activated (void) } /* Draw TEXT_AREA glyphs between START and END of glyph row ROW on - window W, starting at x-position X. X is relative to TEXT_AREA - in W. HL is a face override for drawing the glyphs. */ + window W. X is relative to TEXT_AREA in W. HL is a face override + for drawing the glyphs. */ void -draw_row_with_mouse_face (struct window *w, int x, struct glyph_row *row, - int start_hpos, int end_hpos, - enum draw_glyphs_face hl) +tty_draw_row_with_mouse_face (struct window *w, struct glyph_row *row, + int start_hpos, int end_hpos, + enum draw_glyphs_face hl) { struct frame *f = XFRAME (WINDOW_FRAME (w)); struct tty_display_info *tty = FRAME_TTY (f); diff --git a/src/msdos.h b/src/msdos.h index 7b50abe31e1..fe9964af25e 100644 --- a/src/msdos.h +++ b/src/msdos.h @@ -52,6 +52,8 @@ typedef int XRectangle; #define PIX_TYPE unsigned long #define XDISPLAY +typedef struct tty_display_info Display_Info; + extern struct tty_display_info the_only_display_info; #define FRAME_X_DISPLAY(f) ((Display *) 0) diff --git a/src/xdisp.c b/src/xdisp.c index 73dd7452ad0..275f762caa8 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -23614,9 +23614,8 @@ x_clear_cursor (struct window *w) #endif /* HAVE_WINDOW_SYSTEM */ -/* Implementation of draw_row_with_mouse_face for GUI sessions and - GPM. MSDOS has its own implementation on msdos.c. */ -#ifndef MSDOS +/* Implementation of draw_row_with_mouse_face for GUI sessions, GPM, + and MSDOS. */ void draw_row_with_mouse_face (struct window *w, int start_x, struct glyph_row *row, int start_hpos, int end_hpos, @@ -23629,11 +23628,10 @@ draw_row_with_mouse_face (struct window *w, int start_x, struct glyph_row *row, return; } #endif -#ifdef HAVE_GPM +#if defined (HAVE_GPM) || defined (MSDOS) tty_draw_row_with_mouse_face (w, row, start_hpos, end_hpos, draw); #endif } -#endif /* not MSDOS */ /* EXPORT: Display the active region described by mouse_face_* according to DRAW. */