diff options
author | Sven Gothel <[email protected]> | 2020-01-15 04:58:24 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2020-01-15 04:58:24 +0100 |
commit | 6c9eedf03a196d8718ddccbb47c0166c7c6267b8 (patch) | |
tree | 7360a48adfae88f615929a0cbfcad22fd2caa6f0 /src/newt | |
parent | cfdfa7716422e76123c911a8f70bf84a682875e0 (diff) |
Bug 1421: NEWT OSX Invisible: Refine 'Fake invisible child window' off-viewport position
Ensure it stays out of sight by moving it to 2x width/height of viewport.
Otherwise one could see the child window moving from lower-right to upper-left ;-)
Diffstat (limited to 'src/newt')
-rw-r--r-- | src/newt/classes/jogamp/newt/driver/macosx/WindowDriver.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/newt/classes/jogamp/newt/driver/macosx/WindowDriver.java b/src/newt/classes/jogamp/newt/driver/macosx/WindowDriver.java index 76bb52cd7..68a315390 100644 --- a/src/newt/classes/jogamp/newt/driver/macosx/WindowDriver.java +++ b/src/newt/classes/jogamp/newt/driver/macosx/WindowDriver.java @@ -484,9 +484,10 @@ public class WindowDriver extends WindowImpl implements MutableSurface, DriverCl public void run() { if( useParent && 0 == ( STATE_MASK_VISIBLE & flags) ) { // Fake invisible child window: We can't use true orderOut + // Ensure it stays out of sight by moving it to 2x width/height of viewport. final RectangleImmutable r = getScreen().getViewportInWindowUnits(); setWindowClientTopLeftPointAndSize0(oldWindowHandle, - r.getX()+r.getWidth(), r.getY()+r.getHeight(), + r.getX()+2*r.getWidth(), r.getY()+2*r.getHeight(), width, height, false /* no display */); } else { // Normal visibility |