summaryrefslogtreecommitdiffstats
path: root/Mac/Modules/carbonevt/_CarbonEvtmodule.c
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>2003-12-06 00:00:17 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>2003-12-06 00:00:17 (GMT)
commit67ff6d9930ae7fdb79f7034b65834488f188bd38 (patch)
tree474f894ea5de95111d76953618970dd19e0667c4 /Mac/Modules/carbonevt/_CarbonEvtmodule.c
parentda78a5d5b6867ba412afd9edd9fc2a3ddd71fe60 (diff)
downloadcpython-67ff6d9930ae7fdb79f7034b65834488f188bd38.zip
cpython-67ff6d9930ae7fdb79f7034b65834488f188bd38.tar.gz
cpython-67ff6d9930ae7fdb79f7034b65834488f188bd38.tar.bz2
Finished update to UH 3.4.2.
Diffstat (limited to 'Mac/Modules/carbonevt/_CarbonEvtmodule.c')
-rwxr-xr-xMac/Modules/carbonevt/_CarbonEvtmodule.c33
1 files changed, 33 insertions, 0 deletions
diff --git a/Mac/Modules/carbonevt/_CarbonEvtmodule.c b/Mac/Modules/carbonevt/_CarbonEvtmodule.c
index 097f11a..560b470 100755
--- a/Mac/Modules/carbonevt/_CarbonEvtmodule.c
+++ b/Mac/Modules/carbonevt/_CarbonEvtmodule.c
@@ -1750,6 +1750,35 @@ static PyObject *CarbonEvents_GetLastUserEventTime(PyObject *_self, PyObject *_a
return _res;
}
+static PyObject *CarbonEvents_IsMouseCoalescingEnabled(PyObject *_self, PyObject *_args)
+{
+ PyObject *_res = NULL;
+ Boolean _rv;
+ if (!PyArg_ParseTuple(_args, ""))
+ return NULL;
+ _rv = IsMouseCoalescingEnabled();
+ _res = Py_BuildValue("b",
+ _rv);
+ return _res;
+}
+
+static PyObject *CarbonEvents_SetMouseCoalescingEnabled(PyObject *_self, PyObject *_args)
+{
+ PyObject *_res = NULL;
+ OSStatus _err;
+ Boolean inNewState;
+ Boolean outOldState;
+ if (!PyArg_ParseTuple(_args, "b",
+ &inNewState))
+ return NULL;
+ _err = SetMouseCoalescingEnabled(inNewState,
+ &outOldState);
+ if (_err != noErr) return PyMac_Error(_err);
+ _res = Py_BuildValue("b",
+ outOldState);
+ return _res;
+}
+
static PyObject *CarbonEvents_GetWindowEventTarget(PyObject *_self, PyObject *_args)
{
PyObject *_res = NULL;
@@ -2059,6 +2088,10 @@ static PyMethodDef CarbonEvents_methods[] = {
PyDoc_STR("(GrafPtr inPort, RgnHandle inRegion, Boolean ioWasInRgn) -> (Boolean ioWasInRgn, UInt16 outResult)")},
{"GetLastUserEventTime", (PyCFunction)CarbonEvents_GetLastUserEventTime, 1,
PyDoc_STR("() -> (double _rv)")},
+ {"IsMouseCoalescingEnabled", (PyCFunction)CarbonEvents_IsMouseCoalescingEnabled, 1,
+ PyDoc_STR("() -> (Boolean _rv)")},
+ {"SetMouseCoalescingEnabled", (PyCFunction)CarbonEvents_SetMouseCoalescingEnabled, 1,
+ PyDoc_STR("(Boolean inNewState) -> (Boolean outOldState)")},
{"GetWindowEventTarget", (PyCFunction)CarbonEvents_GetWindowEventTarget, 1,
PyDoc_STR("(WindowPtr inWindow) -> (EventTargetRef _rv)")},
{"GetControlEventTarget", (PyCFunction)CarbonEvents_GetControlEventTarget, 1,