mirror of
https://github.com/shadowfacts/lwjgl2-arm64.git
synced 2026-04-05 06:25:46 +00:00
Mac OS X: Work around AWT shifting the fullscreen window off the screen
This commit is contained in:
parent
f65ae73d47
commit
45607a7c69
3 changed files with 18 additions and 2 deletions
|
|
@ -77,6 +77,7 @@ final class MacOSXDisplay implements DisplayImplementation {
|
|||
}
|
||||
|
||||
public void createWindow(DisplayMode mode, boolean fullscreen, int x, int y) throws LWJGLException {
|
||||
hideUI(fullscreen);
|
||||
close_requested = false;
|
||||
try {
|
||||
frame = new MacOSXFrame(mode, requested_mode, fullscreen, x, y);
|
||||
|
|
@ -98,6 +99,7 @@ final class MacOSXDisplay implements DisplayImplementation {
|
|||
setView(null);
|
||||
frame.syncDispose();
|
||||
frame = null;
|
||||
hideUI(false);
|
||||
}
|
||||
|
||||
public int getGammaRampLength() {
|
||||
|
|
@ -222,6 +224,13 @@ final class MacOSXDisplay implements DisplayImplementation {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* This is an interface to the native Carbon call
|
||||
* SetSystemUIMode. It is used to hide the dock in a way
|
||||
* that will prevent AWT from shifting the fullscreen window
|
||||
*/
|
||||
private native void hideUI(boolean hide);
|
||||
|
||||
native void getMouseDeltas(IntBuffer delta_buffer);
|
||||
|
||||
private native void updateContext();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue