summaryrefslogtreecommitdiffstats
path: root/Modules/_tkinter.c
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1997-07-19 19:57:42 (GMT)
committerGuido van Rossum <guido@python.org>1997-07-19 19:57:42 (GMT)
commit496f8f632bb8199ed4ebf3cd16e0d890f1045b7e (patch)
treee23df9cbe3c49ff4d8c9067b6ac0436db99a0cd5 /Modules/_tkinter.c
parent9cc8a20cd26102fc8b5f210a0e3fa2a92de193b4 (diff)
downloadcpython-496f8f632bb8199ed4ebf3cd16e0d890f1045b7e.zip
cpython-496f8f632bb8199ed4ebf3cd16e0d890f1045b7e.tar.gz
cpython-496f8f632bb8199ed4ebf3cd16e0d890f1045b7e.tar.bz2
Removed remaining support for Tk versions below 4.0.
Diffstat (limited to 'Modules/_tkinter.c')
-rw-r--r--Modules/_tkinter.c35
1 files changed, 7 insertions, 28 deletions
diff --git a/Modules/_tkinter.c b/Modules/_tkinter.c
index d6506b4..1de3372 100644
--- a/Modules/_tkinter.c
+++ b/Modules/_tkinter.c
@@ -35,13 +35,14 @@ PERFORMANCE OF THIS SOFTWARE.
/* TCL/TK VERSION INFO:
Unix:
- This should work with any version from Tcl 4.0 / Tck 7.4.
- Do not use older versions.
+ Tcl/Tk 8.0 (even alpha or beta) or 7.6/4.2 are recommended.
+ This should work with any version from 7.4/4.0 upwards.
+ Tk 3.x is no longer supported.
Mac and Windows:
- Use Tcl 4.1p1 / Tk 7.5p1 or possibly newer.
- It does not seem to work reliably with the original 4.1/7.5
- release. (4.0/7.4 were never released for these platforms.)
+ Use Tcl 8.0 if available (even alpha or beta).
+ The oldest usable version is 4.1p1/7.5p1.
+
*/
#include "Python.h"
@@ -67,7 +68,7 @@ extern int tk_NumMainWindows;
#endif
#if TK_MAJOR_VERSION < 4
-extern struct { Tk_Window win; } *tkMainWindowList;
+#error "Tk 3.x is not supported"
#endif
#ifdef macintosh
@@ -1462,19 +1463,6 @@ EventHook ()
}
#endif /* WITH_READLINE */
-static void
-Tkinter_Cleanup ()
-{
- /* This segfault with Tk 4.0 beta and seems unnecessary there as
- * well */
-
-#if TK_MAJOR_VERSION < 4
- /* XXX rl_deprep_terminal is static, damned! */
- while (tkMainWindowList != 0)
- Tk_DestroyWindow(tkMainWindowList->win);
-#endif
-}
-
/* all errors will be checked in one fell swoop in init_tkinter() */
static void
@@ -1506,8 +1494,6 @@ ins_string(d, name, val)
void
init_tkinter ()
{
- static inited = 0;
-
#ifdef WITH_READLINE
extern int (*rl_event_hook) ();
#endif /* WITH_READLINE */
@@ -1538,13 +1524,6 @@ init_tkinter ()
rl_event_hook = EventHook;
#endif /* WITH_READLINE */
- if (!inited) {
- inited = 1;
- if (Py_AtExit(Tkinter_Cleanup) != 0)
- fprintf(stderr,
- "Tkinter: warning: cleanup procedure not registered\n");
- }
-
if (PyErr_Occurred())
Py_FatalError ("can't initialize module _tkinter");
#ifdef macintosh