From 1be89cc70294a36a54db545fd19f0b4af45edba2 Mon Sep 17 00:00:00 2001 From: William McBrine Date: Thu, 28 Dec 2006 09:51:31 +0000 Subject: [PATCH] Added PDC_CLICK_PERIOD to curspriv.h, instead of hardwiring the delay; made it 150 instead of 100. --- curspriv.h | 5 ++++- dos/pdcscrn.c | 4 ++-- os2/pdcscrn.c | 4 ++-- win32/pdcscrn.c | 4 ++-- x11/x11.c | 6 +++--- 5 files changed, 13 insertions(+), 10 deletions(-) diff --git a/curspriv.h b/curspriv.h index e6620c51..fcc7b6e1 100644 --- a/curspriv.h +++ b/curspriv.h @@ -11,7 +11,7 @@ * See the file maintain.er for details of the current maintainer. * ************************************************************************/ -/* $Id: curspriv.h,v 1.143 2006/12/25 14:12:18 wmcbrine Exp $ */ +/* $Id: curspriv.h,v 1.144 2006/12/28 09:51:31 wmcbrine Exp $ */ /* CURSPRIV.H @@ -135,4 +135,7 @@ void PDC_sync(WINDOW *); #define DIVROUND(num, divisor) ((num) + ((divisor) >> 1)) / (divisor) +#define PDC_CLICK_PERIOD 150 /* time to wait for a click, if + not set by mouseinterval() */ + #endif /* __CURSES_INTERNALS__*/ diff --git a/dos/pdcscrn.c b/dos/pdcscrn.c index bfd5244b..4b9d528b 100644 --- a/dos/pdcscrn.c +++ b/dos/pdcscrn.c @@ -19,7 +19,7 @@ # include #endif -RCSID("$Id: pdcscrn.c,v 1.72 2006/12/24 04:32:21 wmcbrine Exp $"); +RCSID("$Id: pdcscrn.c,v 1.73 2006/12/28 09:51:31 wmcbrine Exp $"); int pdc_adapter; /* screen type */ int pdc_scrnmode; /* default screen mode */ @@ -561,7 +561,7 @@ int PDC_scr_open(int argc, char **argv) SP->lines = PDC_get_rows(); SP->cols = PDC_get_columns(); - SP->mouse_wait = 100; + SP->mouse_wait = PDC_CLICK_PERIOD; /* If the environment variable PDCURSES_BIOS is set, the DOS int10() BIOS calls are used in place of direct video memory diff --git a/os2/pdcscrn.c b/os2/pdcscrn.c index 0f7aae57..a19d6350 100644 --- a/os2/pdcscrn.c +++ b/os2/pdcscrn.c @@ -13,7 +13,7 @@ #include "pdcos2.h" -RCSID("$Id: pdcscrn.c,v 1.62 2006/12/24 04:32:22 wmcbrine Exp $"); +RCSID("$Id: pdcscrn.c,v 1.63 2006/12/28 09:51:31 wmcbrine Exp $"); int pdc_font; /* default font size */ @@ -208,7 +208,7 @@ int PDC_scr_open(int argc, char **argv) SP->lines = PDC_get_rows(); SP->cols = PDC_get_columns(); - SP->mouse_wait = 100; + SP->mouse_wait = PDC_CLICK_PERIOD; /* This code for preserving the current screen */ diff --git a/win32/pdcscrn.c b/win32/pdcscrn.c index 391e494a..e27410dc 100644 --- a/win32/pdcscrn.c +++ b/win32/pdcscrn.c @@ -13,7 +13,7 @@ #include "pdcwin.h" -RCSID("$Id: pdcscrn.c,v 1.74 2006/12/24 04:32:22 wmcbrine Exp $"); +RCSID("$Id: pdcscrn.c,v 1.75 2006/12/28 09:51:31 wmcbrine Exp $"); #define PDC_RESTORE_NONE 0 #define PDC_RESTORE_BUFFER 1 @@ -337,7 +337,7 @@ int PDC_scr_open(int argc, char **argv) SP->cols = ((str = getenv("COLS")) != NULL) ? atoi(str) : PDC_get_columns(); - SP->mouse_wait = 100; + SP->mouse_wait = PDC_CLICK_PERIOD; if (SP->lines < 2 || SP->lines > csbi.dwMaximumWindowSize.Y) { diff --git a/x11/x11.c b/x11/x11.c index 0908a861..5e24fd6d 100644 --- a/x11/x11.c +++ b/x11/x11.c @@ -32,7 +32,7 @@ #include #include -RCSID("$Id: x11.c,v 1.77 2006/12/28 09:35:32 wmcbrine Exp $"); +RCSID("$Id: x11.c,v 1.78 2006/12/28 09:51:31 wmcbrine Exp $"); #ifndef XPOINTER_TYPEDEFED typedef char * XPointer; @@ -350,8 +350,8 @@ static XtResource app_resources[] = RPIXEL(borderColor, BorderColor, Black), - RINT(doubleClickPeriod, DoubleClickPeriod, 200), - RINT(clickPeriod, ClickPeriod, 100), + RINT(doubleClickPeriod, DoubleClickPeriod, (PDC_CLICK_PERIOD * 2)), + RINT(clickPeriod, ClickPeriod, PDC_CLICK_PERIOD), RINT(scrollbarWidth, ScrollbarWidth, 15), RINT(cursorBlinkRate, CursorBlinkRate, 0),