]> Dogcows Code - chaz/openbox/blobdiff - src/python.cc
grab the keyboard during move/resize to make sure the popup doesnt get left onscreen...
[chaz/openbox] / src / python.cc
index 9feddbd8fb9b97ebcb4684fd7fea24917aac1d36..2a9a912a2b583bd457b9000bd99078a528bb92a6 100644 (file)
@@ -144,6 +144,21 @@ PyObject *kungrab()
   Py_INCREF(Py_None); return Py_None;
 }
 
+PyObject *mgrab(int screen)
+{
+  if (!ob::openbox->bindings()->grabPointer(screen)) {
+    PyErr_SetString(PyExc_RuntimeError,"Unable to grab pointer.");
+    return NULL;
+  }
+  Py_INCREF(Py_None); return Py_None;
+}
+
+PyObject *mungrab()
+{
+  ob::openbox->bindings()->ungrabPointer();
+  Py_INCREF(Py_None); return Py_None;
+}
+
 PyObject *kbind(PyObject *keylist, ob::KeyContext::KC context, PyObject *func)
 {
   if (!PyCallable_Check(func)) {
This page took 0.020633 seconds and 4 git commands to generate.