]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/gtk/misc.cpp
don't log mouse events by default
[wxWidgets.git] / wxPython / src / gtk / misc.cpp
index 4b65fa797b5c666304aaa4c3ebe30ad0de888d45..db54d16b1663582374e5bdd1dd71e3ca672cbda1 100644 (file)
@@ -105,13 +105,13 @@ static PyObject* t_output_helper(PyObject* target, PyObject* o) {
         dest = reg1.GetBox();
 
         if (dest != wxRect(0,0,0,0)) {
-            bool doSave = wxPyRestoreThread();
+            wxPyTState* state = wxPyBeginBlockThreads();
             wxRect* newRect = new wxRect(dest);
             obj = wxPyConstructObject((void*)newRect, "wxRect");
             PyObject* one = PyInt_FromLong(1);
             PyObject_SetAttrString(obj, "thisown", one);
             Py_DECREF(one);
-            wxPySaveThread(doSave);
+            wxPyEndBlockThreads(state);
             return obj;
         }
         Py_INCREF(Py_None);