diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2021-01-31 22:34:48 -0700 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2021-01-31 22:34:48 -0700 |
commit | d4d613629b59d2eadd80026cab6c9dabc92cab24 (patch) | |
tree | d31086a817251dddb847d027661d218c1ecd6540 /src/term.c | |
parent | fdb813e529602914360fc2d0cf22e42e32e6905f (diff) | |
parent | a5438ee11ad052e71334dcfb2db51fb9123411e5 (diff) | |
download | emacs-d4d613629b59d2eadd80026cab6c9dabc92cab24.tar.gz |
Merge remote-tracking branch 'origin/master' into athena/unstable
Diffstat (limited to 'src/term.c')
-rw-r--r-- | src/term.c | 39 |
1 files changed, 22 insertions, 17 deletions
diff --git a/src/term.c b/src/term.c index 2e2ab2bf438..1059b0669a7 100644 --- a/src/term.c +++ b/src/term.c @@ -790,7 +790,7 @@ tty_write_glyphs (struct frame *f, struct glyph *string, int len) cmcheckmagic (tty); } -#ifdef HAVE_GPM /* Only used by GPM code. */ +#ifndef DOS_NT static void tty_write_glyphs_with_face (register struct frame *f, register struct glyph *string, @@ -847,6 +847,7 @@ tty_write_glyphs_with_face (register struct frame *f, register struct glyph *str cmcheckmagic (tty); } + #endif /* An implementation of insert_glyphs for termcap frames. */ @@ -2380,23 +2381,9 @@ frame's terminal). */) Mouse ***********************************************************************/ -#ifdef HAVE_GPM - -void -term_mouse_moveto (int x, int y) -{ - /* TODO: how to set mouse position? - const char *name; - int fd; - name = (const char *) ttyname (0); - fd = emacs_open (name, O_WRONLY, 0); - SOME_FUNCTION (x, y, fd); - emacs_close (fd); - last_mouse_x = x; - last_mouse_y = y; */ -} +#ifndef DOS_NT -/* Implementation of draw_row_with_mouse_face for TTY/GPM. */ +/* Implementation of draw_row_with_mouse_face for TTY/GPM and macOS. */ void tty_draw_row_with_mouse_face (struct window *w, struct glyph_row *row, int start_hpos, int end_hpos, @@ -2428,6 +2415,24 @@ tty_draw_row_with_mouse_face (struct window *w, struct glyph_row *row, cursor_to (f, save_y, save_x); } +#endif + +#ifdef HAVE_GPM + +void +term_mouse_moveto (int x, int y) +{ + /* TODO: how to set mouse position? + const char *name; + int fd; + name = (const char *) ttyname (0); + fd = emacs_open (name, O_WRONLY, 0); + SOME_FUNCTION (x, y, fd); + emacs_close (fd); + last_mouse_x = x; + last_mouse_y = y; */ +} + /* Return the current time, as a Time value. Wrap around on overflow. */ static Time current_Time (void) |