summaryrefslogtreecommitdiffstats
path: root/Mac/Include
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>1997-06-03 15:27:31 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>1997-06-03 15:27:31 (GMT)
commit4a79a4b0a9c45c2ea812de3f839c9f7327e871c8 (patch)
tree1d701b7fdbb038e6cef17e365808e3257dfdfb65 /Mac/Include
parentc24751b57a4e9761efe29b4ed6594af6fa955747 (diff)
downloadcpython-4a79a4b0a9c45c2ea812de3f839c9f7327e871c8.zip
cpython-4a79a4b0a9c45c2ea812de3f839c9f7327e871c8.tar.gz
cpython-4a79a4b0a9c45c2ea812de3f839c9f7327e871c8.tar.bz2
Removed SetScheduleTimes and PyMac_DoYieldEnabled
Added [GS]etSchedParams Added parameter to PyMac_HandleEvent (safe to run python code at this point) Removed various cruft
Diffstat (limited to 'Mac/Include')
-rw-r--r--Mac/Include/macglue.h19
1 files changed, 13 insertions, 6 deletions
diff --git a/Mac/Include/macglue.h b/Mac/Include/macglue.h
index 6b2cb41..c0b842c 100644
--- a/Mac/Include/macglue.h
+++ b/Mac/Include/macglue.h
@@ -31,6 +31,16 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#include <Events.h>
#include <StandardFile.h>
+/* Scheduler parameters */
+typedef struct {
+ int check_interrupt; /* if true check for command-dot */
+ int process_events; /* if nonzero enable evt processing, this mask */
+ int besocial; /* Be social, give up CPU now and again */
+ double check_interval; /* how often to check */
+ double bg_yield; /* yield at most so long when in background */
+} PyMacSchedParams;
+
+
#ifdef GENERATINGCFM /* Defined to 0 or 1 in Universal headers */
#define HAVE_UNIVERSAL_HEADERS
#endif
@@ -45,7 +55,6 @@ void PyMac_FixGUSIcd Py_PROTO((void)); /* Workaround for GUSI chdir() call */
char *PyMac_StrError(int); /* strerror with mac errors */
-extern int PyMac_DoYieldEnabled; /* Don't do eventloop when false */
#ifdef USE_GUSI
extern int PyMac_ConsoleIsDead; /* True when exiting */
extern void PyMac_SetGUSISpin(void); /* Install our private GUSI spin routine */
@@ -62,14 +71,12 @@ extern int PyMac_GetArgv Py_PROTO((char ***, int)); /* Get argc, argv (from maca
extern PyObject *PyMac_OSErrException; /* Exception for OSErr */
PyObject *PyMac_GetOSErrException(void); /* Initialize & return it */
-#ifdef USE_MACTCP
-int PyMac_Idle Py_PROTO((void)); /* Idle routine */
-#endif
void PyMac_Yield Py_PROTO((void)); /* optional idle routine for mainloop */
-void PyMac_SetYield Py_PROTO((long, long, long, long)); /* Set timeouts */
+void PyMac_GetSchedParams Py_PROTO((PyMacSchedParams *)); /* Get schedulers params */
+void PyMac_SetSchedParams Py_PROTO((PyMacSchedParams *)); /* Set schedulers params */
PyObject *PyErr_Mac(PyObject *, int); /* Exception with a mac error */
PyObject *PyMac_Error(OSErr); /* Uses PyMac_GetOSErrException */
-void PyMac_HandleEvent Py_PROTO((EventRecord *)); /* Handle one event, if possible */
+void PyMac_HandleEvent Py_PROTO((EventRecord *, int)); /* Handle one event, if possible */
void PyMac_InitMenuBar(void); /* Setup menu bar as we want it */