Skip to content

Commit

Permalink
Update layer bounds fix to Java 1.8 and later (OS X)
Browse files Browse the repository at this point in the history
  • Loading branch information
b23prodtm committed May 1, 2015
1 parent b36d6e4 commit 397b2e9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/java/org/lwjgl/opengl/MacOSXCanvasPeerInfo.java
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ protected void initHandle(Canvas component) throws LWJGLException {
// where the older cocoaViewRef NSView method maybe be available.
forceCALayer = false;
} // fix for CALayer position not covering Canvas due to a Java 7 bug (don't autoresize, use componentlistener)
else if (javaVersion.startsWith("1.7")) {
else /*if (javaVersion.startsWith("1.7")) */{
autoResizable = false;
}

Expand All @@ -87,7 +87,7 @@ else if (javaVersion.startsWith("1.7")) {
// reverse oY
window_handle = nInitHandle(awt_surface.lockAndGetHandle(component), getHandle(), window_handle, forceCALayer, autoResizable, rtLoc.x - left, peer.getHeight() - rtLoc.y + top - component.getHeight());

if (javaVersion.startsWith("1.7")) {
if (!(javaVersion.startsWith("1.5") || javaVersion.startsWith("1.6"))){/*javaVersion.startsWith("1.7")) {*/
// fix for CALayer position not covering Canvas due to a Java 7 bug
// http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7172187
addComponentListener(component);
Expand Down

0 comments on commit 397b2e9

Please sign in to comment.