]> Dogcows Code - chaz/openbox/commitdiff
move windows based on their *frame* not the client
authorDana Jansens <danakj@orodu.net>
Mon, 3 Feb 2003 03:04:31 +0000 (03:04 +0000)
committerDana Jansens <danakj@orodu.net>
Mon, 3 Feb 2003 03:04:31 +0000 (03:04 +0000)
scripts/motion.py

index a6602e2d0b04683663b516eaed5975af1596f446..b0a6651def2d16fa8e6a946bd4aa24791d523bbd 100644 (file)
@@ -92,8 +92,9 @@ _last_y = 0
 def _do_move():
     global _screen, _client, _cx, _cy, _dx, _dy
 
-    x = _cx + _dx
-    y = _cy + _dy
+    # get destination x/y for the *frame*
+    x = _cx + _dx + _client.frame.rect().x() - _client.area().x()
+    y = _cy + _dy + _client.frame.rect().y() - _client.area().y()
 
     global edge_resistance
     global _last_x, _last_y
@@ -133,7 +134,8 @@ def _do_move():
         # draw the outline ...
         f=0
     else:
-        _client.move(x, y)
+        print "moving " + str(x) + " " + str(y)
+        _client.move(x, y, 1) # move the frame to the position
 
     global move_popup
     if move_popup:
This page took 0.023636 seconds and 4 git commands to generate.