X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2Factions.cc;h=ceb55b6ccac677c12c7b1a86d289e7bc8cd1417a;hb=db23fe0584b9d7ece147ef74c7ad6d45ff7ba6fd;hp=af33f51c60d562914dd31cf7db99a2e4b4099f86;hpb=772ff27864b724c884ca5681fedc42711c63ec82;p=chaz%2Fopenbox diff --git a/src/actions.cc b/src/actions.cc index af33f51c..ceb55b6c 100644 --- a/src/actions.cc +++ b/src/actions.cc @@ -147,10 +147,14 @@ void OBActions::keyPressHandler(const XKeyEvent &e) void OBActions::motionHandler(const XMotionEvent &e) { + if (!e.same_screen) return; // this just gets stupid + + _dx = e.x - _posqueue[0]->pos.x(); + _dy = e.y - _posqueue[0]->pos.y(); + // XXX: i can envision all sorts of crazy shit with this.. gestures, etc printf("GUILE: MOTION: win %lx modifiers %u x %d y %d\n", - (long)e.window, e.state, - e.x - _posqueue[0]->pos.x(), e.y - _posqueue[0]->pos.y()); + (long)e.window, e.state, _dx, _dy); }