ecere;gui;drivers;XInterface; (#850) fix for unity double menu bar and mouse pointer...
authorRejean Loyer <rejean.loyer@gmail.com>
Sun, 25 Aug 2013 00:37:52 +0000 (20:37 -0400)
committerJerome St-Louis <jerome@ecere.com>
Sun, 25 Aug 2013 07:34:54 +0000 (03:34 -0400)
ecere/src/gui/drivers/XInterface.ec

index 670ccc6..87225bc 100644 (file)
@@ -1866,27 +1866,26 @@ class XInterface : Interface
                          &fill, &data) == Success && data)
                      {
                         long *extents = (long *)data;
-                        bool hadFrameExtents = windowData.gotFrameExtents;
+                        bool change = extents[0] != windowData.decor.left ||
+                                      extents[1] != windowData.decor.right ||
+                                      extents[2] != windowData.decor.top ||
+                                      extents[3] != windowData.decor.bottom;
                         windowData.decor =
                         {
                            left = (int)extents[0], right  = (int)extents[1],
                            top  = (int)extents[2], bottom = (int)extents[3]
                         };
                         windowData.gotFrameExtents = true;
+                        if(change)
                         {
                            int x, y, w, h;
                            window.ComputeAnchors(
                               window.normalAnchor,
                               window.normalSizeAnchor,
                               &x, &y, &w, &h);
-                           if(!hadFrameExtents) // || window.state == normal)
-                           {
-                              bool isMaximized = window.state == maximized;
-                              window.Position(x, y, w, h, true, true, true, true, false, true);
-                              UpdateRootWindow(window);
-                           }
+                           window.Position(x, y, w, h, true, true, true, true, false, false);
+                           UpdateRootWindow(window);
                         }
-
                         XFree(data);
                      }
                      else