aboutsummaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
authorFumitoshi UKAI <ukai@debian.or.jp>2002-11-15 15:36:48 +0000
committerFumitoshi UKAI <ukai@debian.or.jp>2002-11-15 15:36:48 +0000
commit7eb27d5b8b9d7d8979c981c67e484546f902f16c (patch)
tree193ed7810e2333268d16806f714937c1f5cd501b /main.c
parent[w3m-dev 03432] Re: tab browser (diff)
downloadw3m-7eb27d5b8b9d7d8979c981c67e484546f902f16c.tar.gz
w3m-7eb27d5b8b9d7d8979c981c67e484546f902f16c.zip
[w3m-dev 03433] cygwin console on Win9X
* configure (config.h): SUPPORT_WIN9X_CONSOLE_MBCS * linein.c (inputLineHistSearch): enable_win9x_console_input() disable_win9x_console_input() * main.c (mouse): cygin_mouse_btn_swapped * terms.c (is_xterm): static (isLocalConsole): added (cygwin_mouse_btn_swapped): added (check_win32_console): deleted (check_win9x): added (init_win32_console_handle): check ttyslot() (enable_win9x_console_input): added (disable_win9x_console_input): added (read_win32_console_input): delete ifdef MOUSE (cmp_tv): deleted (subtract_tv): deleted (GetConsoleHwnd): added (cygwin_version): added (select_or_poll_win32_console): deleted (check_cygwin_console): added (select_win32_console): deleted (set_tty): check_cygin_console() (term_title): SetConsoleTitle() (CYGWIN_ON): added (CYGIN_OFF): added (mouse_init): NEED_CYGWIN_ON (mouse_end): NEED_CYGWIN_OFF * terms.h (cygwin_mouse_btn_swapped): added (enable_win9x_console_input): added (disable_win9x_console_input): added (NEED_CYGWIN_ON): added (NEED_CYGWIN_OFF): added From: WATANABE Katsuyuki <katsuyuki_1.watanabe@toppan.co.jp>
Diffstat (limited to 'main.c')
-rw-r--r--main.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/main.c b/main.c
index e85e64c..6bff67c 100644
--- a/main.c
+++ b/main.c
@@ -1,4 +1,4 @@
-/* $Id: main.c,v 1.133 2002/11/15 15:21:07 ukai Exp $ */
+/* $Id: main.c,v 1.134 2002/11/15 15:36:48 ukai Exp $ */
#define MAINPROGRAM
#include "fm.h"
#include <signal.h>
@@ -4895,6 +4895,14 @@ mouse()
int btn, x, y;
btn = (unsigned char)getch() - 32;
+#if defined(__CYGWIN__)
+ if (cygwin_mouse_btn_swapped) {
+ if (btn == MOUSE_BTN2_DOWN)
+ btn = MOUSE_BTN3_DOWN;
+ else if (btn == MOUSE_BTN3_DOWN)
+ btn = MOUSE_BTN2_DOWN;
+ }
+#endif
x = (unsigned char)getch() - 33;
if (x < 0)
x += 0x100;