ecere/gui/drivers/XInterface: Break the anchors upon moving fixed windows
authorJerome St-Louis <jerome@ecere.com>
Sat, 8 Feb 2014 14:08:09 +0000 (21:08 +0700)
committerJerome St-Louis <jerome@ecere.com>
Sun, 9 Feb 2014 03:39:26 +0000 (10:39 +0700)
ecere/src/gui/drivers/XInterface.ec

index 70592ff..bdb741f 100644 (file)
@@ -1928,6 +1928,15 @@ class XInterface : Interface
                         h += window.size.h - window.clientSize.h;
                         */
                      }
+
+                     // Break the anchors for moveable/resizable windows
+                     if(window.style.fixed && window.state == normal)
+                     {
+                        window.normalAnchor = Anchor { left = x, top = y };
+                        window.normalSizeAnchor = SizeAnchor { { w, h } };
+                        window.anchored = false;
+                     }
+
                      window.Position(x, y, w, h, true, true, true, true, false, false);
                   }
                   break;