mirror of
https://github.com/Stichting-MINIX-Research-Foundation/pkgsrc-ng.git
synced 2025-09-14 23:06:08 -04:00
87 lines
3.4 KiB
Plaintext
87 lines
3.4 KiB
Plaintext
$NetBSD: patch-ah,v 1.3 2010/09/04 05:12:00 obache Exp $
|
|
|
|
--- Modules/_cursesmodule.c.orig 2010-08-05 16:35:53.000000000 +0000
|
|
+++ Modules/_cursesmodule.c
|
|
@@ -317,17 +317,9 @@ Window_NoArg2TupleReturnFunction(getpary
|
|
|
|
Window_OneArgNoReturnFunction(clearok, int, "i;True(1) or False(0)")
|
|
Window_OneArgNoReturnFunction(idlok, int, "i;True(1) or False(0)")
|
|
-#if defined(__NetBSD__)
|
|
-Window_OneArgNoReturnVoidFunction(keypad, int, "i;True(1) or False(0)")
|
|
-#else
|
|
Window_OneArgNoReturnFunction(keypad, int, "i;True(1) or False(0)")
|
|
-#endif
|
|
Window_OneArgNoReturnFunction(leaveok, int, "i;True(1) or False(0)")
|
|
-#if defined(__NetBSD__)
|
|
-Window_OneArgNoReturnVoidFunction(nodelay, int, "i;True(1) or False(0)")
|
|
-#else
|
|
Window_OneArgNoReturnFunction(nodelay, int, "i;True(1) or False(0)")
|
|
-#endif
|
|
Window_OneArgNoReturnFunction(notimeout, int, "i;True(1) or False(0)")
|
|
Window_OneArgNoReturnFunction(scrollok, int, "i;True(1) or False(0)")
|
|
Window_OneArgNoReturnFunction(winsdelln, int, "i;nlines")
|
|
@@ -886,11 +878,7 @@ PyCursesWindow_GetKey(PyCursesWindowObje
|
|
return Py_BuildValue("c", rtn);
|
|
} else {
|
|
const char *knp;
|
|
-#if defined(__NetBSD__)
|
|
- knp = unctrl(rtn);
|
|
-#else
|
|
knp = keyname(rtn);
|
|
-#endif
|
|
return PyString_FromString((knp == NULL) ? "" : knp);
|
|
}
|
|
}
|
|
@@ -2100,7 +2088,6 @@ PyCursesWindow_NoOutRefresh(PyCursesWind
|
|
}
|
|
#endif /* HAVE_CURSES_IS_TERM_RESIZED */
|
|
|
|
-#if !defined(__NetBSD__)
|
|
static PyObject *
|
|
PyCurses_KeyName(PyObject *self, PyObject *args)
|
|
{
|
|
@@ -2119,7 +2106,6 @@ PyCursesWindow_NoOutRefresh(PyCursesWind
|
|
|
|
return PyString_FromString((knp == NULL) ? "" : (char *)knp);
|
|
}
|
|
-#endif
|
|
|
|
static PyObject *
|
|
PyCurses_KillChar(PyObject *self)
|
|
@@ -2664,9 +2650,7 @@ PyCursesWindow_NoOutRefresh(PyCursesWind
|
|
#ifdef HAVE_CURSES_IS_TERM_RESIZED
|
|
{"is_term_resized", (PyCFunction)PyCurses_Is_Term_Resized, METH_VARARGS},
|
|
#endif
|
|
-#if !defined(__NetBSD__)
|
|
{"keyname", (PyCFunction)PyCurses_KeyName, METH_VARARGS},
|
|
-#endif
|
|
{"killchar", (PyCFunction)PyCurses_KillChar, METH_NOARGS},
|
|
{"longname", (PyCFunction)PyCurses_longname, METH_NOARGS},
|
|
{"meta", (PyCFunction)PyCurses_Meta, METH_VARARGS},
|
|
@@ -2775,9 +2759,7 @@ PyCursesWindow_NoOutRefresh(PyCursesWind
|
|
SetDictInt("A_DIM", A_DIM);
|
|
SetDictInt("A_BOLD", A_BOLD);
|
|
SetDictInt("A_ALTCHARSET", A_ALTCHARSET);
|
|
-#if !defined(__NetBSD__)
|
|
SetDictInt("A_INVIS", A_INVIS);
|
|
-#endif
|
|
SetDictInt("A_PROTECT", A_PROTECT);
|
|
SetDictInt("A_CHARTEXT", A_CHARTEXT);
|
|
SetDictInt("A_COLOR", A_COLOR);
|
|
@@ -2849,7 +2831,6 @@ PyCursesWindow_NoOutRefresh(PyCursesWind
|
|
int key;
|
|
char *key_n;
|
|
char *key_n2;
|
|
-#if !defined(__NetBSD__)
|
|
for (key=KEY_MIN;key < KEY_MAX; key++) {
|
|
key_n = (char *)keyname(key);
|
|
if (key_n == NULL || strcmp(key_n,"UNKNOWN KEY")==0)
|
|
@@ -2877,7 +2858,6 @@ PyCursesWindow_NoOutRefresh(PyCursesWind
|
|
if (key_n2 != key_n)
|
|
free(key_n2);
|
|
}
|
|
-#endif
|
|
SetDictInt("KEY_MIN", KEY_MIN);
|
|
SetDictInt("KEY_MAX", KEY_MAX);
|
|
}
|