diff options
author | Andrew Svetlov <andrew.svetlov@gmail.com> | 2012-10-04 19:10:09 (GMT) |
---|---|---|
committer | Andrew Svetlov <andrew.svetlov@gmail.com> | 2012-10-04 19:10:09 (GMT) |
commit | 456b2b8777533ce0edf1690203ee50e6e59d9fab (patch) | |
tree | 4ca4f28840790a089abe3fa0aa3a2ce46368d936 /Modules | |
parent | 65e9c57369af9acb3909057545168f72b7dd5ba5 (diff) | |
download | cpython-456b2b8777533ce0edf1690203ee50e6e59d9fab.zip cpython-456b2b8777533ce0edf1690203ee50e6e59d9fab.tar.gz cpython-456b2b8777533ce0edf1690203ee50e6e59d9fab.tar.bz2 |
Issue #14446: Remove deprecated tkinter functions
Thanks to Michael Driscoll
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/_tkinter.c | 88 |
1 files changed, 0 insertions, 88 deletions
diff --git a/Modules/_tkinter.c b/Modules/_tkinter.c index 70f4703..c39d73f 100644 --- a/Modules/_tkinter.c +++ b/Modules/_tkinter.c @@ -1332,42 +1332,6 @@ Tkapp_Call(PyObject *selfptr, PyObject *args) static PyObject * -Tkapp_GlobalCall(PyObject *self, PyObject *args) -{ - /* Could do the same here as for Tkapp_Call(), but this is not used - much, so I can't be bothered. Unfortunately Tcl doesn't export a - way for the user to do what all its Global* variants do (save and - reset the scope pointer, call the local version, restore the saved - scope pointer). */ - - char *cmd; - PyObject *res = NULL; - - if (PyErr_WarnEx(PyExc_DeprecationWarning, - "globalcall is deprecated and will be removed in 3.4", - 1) < 0) - return 0; - - CHECK_TCL_APPARTMENT; - - cmd = Merge(args); - if (cmd) { - int err; - ENTER_TCL - err = Tcl_GlobalEval(Tkapp_Interp(self), cmd); - ENTER_OVERLAP - if (err == TCL_ERROR) - res = Tkinter_Error(self); - else - res = PyUnicode_FromString(Tkapp_Result(self)); - LEAVE_OVERLAP_TCL - ckfree(cmd); - } - - return res; -} - -static PyObject * Tkapp_Eval(PyObject *self, PyObject *args) { char *script; @@ -1391,34 +1355,6 @@ Tkapp_Eval(PyObject *self, PyObject *args) } static PyObject * -Tkapp_GlobalEval(PyObject *self, PyObject *args) -{ - char *script; - PyObject *res = NULL; - int err; - - if (PyErr_WarnEx(PyExc_DeprecationWarning, - "globaleval is deprecated and will be removed in 3.4", - 1) < 0) - return 0; - - if (!PyArg_ParseTuple(args, "s:globaleval", &script)) - return NULL; - - CHECK_TCL_APPARTMENT; - - ENTER_TCL - err = Tcl_GlobalEval(Tkapp_Interp(self), script); - ENTER_OVERLAP - if (err == TCL_ERROR) - res = Tkinter_Error(self); - else - res = PyUnicode_FromString(Tkapp_Result(self)); - LEAVE_OVERLAP_TCL - return res; -} - -static PyObject * Tkapp_EvalFile(PyObject *self, PyObject *args) { char *fileName; @@ -1961,27 +1897,6 @@ Tkapp_Split(PyObject *self, PyObject *args) return v; } -static PyObject * -Tkapp_Merge(PyObject *self, PyObject *args) -{ - char *s; - PyObject *res = NULL; - - if (PyErr_WarnEx(PyExc_DeprecationWarning, - "merge is deprecated and will be removed in 3.4", - 1) < 0) - return 0; - - s = Merge(args); - - if (s) { - res = PyUnicode_FromString(s); - ckfree(s); - } - - return res; -} - /** Tcl Command **/ @@ -2695,9 +2610,7 @@ static PyMethodDef Tkapp_methods[] = {"willdispatch", Tkapp_WillDispatch, METH_NOARGS}, {"wantobjects", Tkapp_WantObjects, METH_VARARGS}, {"call", Tkapp_Call, METH_VARARGS}, - {"globalcall", Tkapp_GlobalCall, METH_VARARGS}, {"eval", Tkapp_Eval, METH_VARARGS}, - {"globaleval", Tkapp_GlobalEval, METH_VARARGS}, {"evalfile", Tkapp_EvalFile, METH_VARARGS}, {"record", Tkapp_Record, METH_VARARGS}, {"adderrorinfo", Tkapp_AddErrorInfo, METH_VARARGS}, @@ -2716,7 +2629,6 @@ static PyMethodDef Tkapp_methods[] = {"exprboolean", Tkapp_ExprBoolean, METH_VARARGS}, {"splitlist", Tkapp_SplitList, METH_VARARGS}, {"split", Tkapp_Split, METH_VARARGS}, - {"merge", Tkapp_Merge, METH_VARARGS}, {"createcommand", Tkapp_CreateCommand, METH_VARARGS}, {"deletecommand", Tkapp_DeleteCommand, METH_VARARGS}, #ifdef HAVE_CREATEFILEHANDLER |