Mercurial > cpython-lru_cache-weakref
diff Mac/Modules/macosmodule.c @ 4309:ecbeb445f62e legacy-trunk
Fixed macos.splash to actually *draw* the splash box:-)
| author | Jack Jansen <jack.jansen@cwi.nl> |
|---|---|
| date | Sun, 15 Sep 1996 22:12:00 +0000 |
| parents | 6f715bff17e4 |
| children | b03ab35d52df |
line wrap: on
line diff
--- a/Mac/Modules/macosmodule.c Sun Sep 15 22:11:25 1996 +0000 +++ b/Mac/Modules/macosmodule.c Sun Sep 15 22:12:00 1996 +0000 @@ -500,15 +500,19 @@ static PyObject * MacOS_splash(PyObject *self, PyObject *args) { - int resid; + int resid = -1; static DialogPtr curdialog; - if (!PyArg_ParseTuple(args, "i", &resid)) + if (!PyArg_ParseTuple(args, "|i", &resid)) return NULL; if (curdialog) DisposeDialog(curdialog); - curdialog = GetNewDialog(resid, NULL, (WindowPtr)-1); + if ( resid != -1 ) { + curdialog = GetNewDialog(resid, NULL, (WindowPtr)-1); + if ( curdialog ) + DrawDialog(curdialog); + } Py_INCREF(Py_None); return Py_None; }
