mirror of
https://github.com/JFormDesigner/FlatLaf.git
synced 2025-12-06 14:00:55 +03:00
Window decorations: glass pane no longer overlaps the FlatLaf window title bar (issue #630)
This commit is contained in:
@@ -108,6 +108,7 @@ public class FlatInspector
|
||||
private Window window;
|
||||
|
||||
private boolean enabled;
|
||||
private Object oldGlassPaneFullHeight;
|
||||
private Component lastComponent;
|
||||
private int lastX;
|
||||
private int lastY;
|
||||
@@ -258,6 +259,14 @@ public class FlatInspector
|
||||
|
||||
this.enabled = enabled;
|
||||
|
||||
// make sure that glass pane has full height if enabled
|
||||
if( enabled ) {
|
||||
oldGlassPaneFullHeight = rootPane.getClientProperty( FlatClientProperties.GLASS_PANE_FULL_HEIGHT );
|
||||
rootPane.putClientProperty( FlatClientProperties.GLASS_PANE_FULL_HEIGHT, true );
|
||||
rootPane.validate();
|
||||
} else
|
||||
rootPane.putClientProperty( FlatClientProperties.GLASS_PANE_FULL_HEIGHT, oldGlassPaneFullHeight );
|
||||
|
||||
// make sure that glass pane is not opaque, which is not the case in WebLaF
|
||||
((JComponent)rootPane.getGlassPane()).setOpaque( false );
|
||||
|
||||
|
||||
Reference in New Issue
Block a user