summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2023-01-14 20:18:39 +0100
committerSven Gothel <[email protected]>2023-01-14 20:18:39 +0100
commitd2d1b56db362f2a5ce45e034141acb52f5254770 (patch)
tree53435a47c57144cf361ad479d956f2ef630999c4 /src
parent4756314cf631f180aad89d54d35e51a470667a89 (diff)
MacOS: MacOSXCGLContext: Simplify version flags, remove Tiger, add Mojave.
Diffstat (limited to 'src')
-rw-r--r--src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java26
1 files changed, 20 insertions, 6 deletions
diff --git a/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java b/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java
index 38f5bb727..df17cedb3 100644
--- a/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java
+++ b/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java
@@ -101,16 +101,30 @@ public class MacOSXCGLContext extends GLContextImpl
boolean swapBuffers();
}
- /* package */ static final boolean isTigerOrLater;
- /* package */ static final boolean isLionOrLater;
- /* package */ static final boolean isMavericksOrLater;
+ /* package */ static final boolean isLionOrLater; // >= 10.7.0
+ /* package */ static final boolean isMavericksOrLater; // >= 10.9.0
+ /* package */ static final boolean isMojaveOrLater; // >= 10.14.0
private static final boolean DEBUG1398;
static {
final VersionNumber osvn = Platform.getOSVersionNumber();
- isTigerOrLater = osvn.compareTo(Platform.OSXVersion.Tiger) >= 0;
- isLionOrLater = osvn.compareTo(Platform.OSXVersion.Lion) >= 0;
- isMavericksOrLater = osvn.compareTo(Platform.OSXVersion.Mavericks) >= 0;
+ if( osvn.compareTo(Platform.OSXVersion.Mojave) >= 0 ) {
+ isLionOrLater = true;
+ isMavericksOrLater = true;
+ isMojaveOrLater = true;
+ } else if( osvn.compareTo(Platform.OSXVersion.Mavericks) >= 0 ) {
+ isLionOrLater = true;
+ isMavericksOrLater = true;
+ isMojaveOrLater = false;
+ } else if( osvn.compareTo(Platform.OSXVersion.Lion) >= 0 ) {
+ isLionOrLater = true;
+ isMavericksOrLater = false;
+ isMojaveOrLater = false;
+ } else {
+ isLionOrLater = false;
+ isMavericksOrLater = false;
+ isMojaveOrLater = false;
+ }
DEBUG1398 = Debug.debug("Bug1398");
}