diff options
author | Sven Gothel <[email protected]> | 2009-03-13 11:55:23 +0000 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2009-03-13 11:55:23 +0000 |
commit | a74f1100b11eb3a6944a73eea48bf17d14ede8c1 (patch) | |
tree | 48a1d2e9fb9a7beb0c71ce016104022e79d736d3 /src/classes/com/sun/opengl/impl/GLDrawableImpl.java | |
parent | 3f0266e5d20216f68f515a943ad647d01e0ff567 (diff) |
New package Native Window Interface 'java.media.nwi',
to loose JOGL dependencies for the moved interfaces, mainly NativeWindow.
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1863 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/classes/com/sun/opengl/impl/GLDrawableImpl.java')
-rw-r--r-- | src/classes/com/sun/opengl/impl/GLDrawableImpl.java | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/src/classes/com/sun/opengl/impl/GLDrawableImpl.java b/src/classes/com/sun/opengl/impl/GLDrawableImpl.java index 0818ac1c4..46c79cf2b 100644 --- a/src/classes/com/sun/opengl/impl/GLDrawableImpl.java +++ b/src/classes/com/sun/opengl/impl/GLDrawableImpl.java @@ -39,19 +39,20 @@ package com.sun.opengl.impl; +import javax.media.nwi.*; import javax.media.opengl.*; public abstract class GLDrawableImpl implements GLDrawable { - private GLCapabilities requestedCapabilities; + private NWCapabilities requestedCapabilities; protected GLDrawableImpl(GLDrawableFactory factory, NativeWindow comp, - GLCapabilities requestedCapabilities, + NWCapabilities requestedCapabilities, boolean realized) { this.factory = factory; this.component = comp; this.requestedCapabilities = - (requestedCapabilities == null) ? null : (GLCapabilities) requestedCapabilities.clone(); + (requestedCapabilities == null) ? null : (NWCapabilities) requestedCapabilities.clone(); this.realized = realized; } @@ -72,20 +73,20 @@ public abstract class GLDrawableImpl implements GLDrawable { return GLContextImpl.toHexString(hex); } - protected GLCapabilities getRequestedGLCapabilities() { + protected NWCapabilities getRequestedNWCapabilities() { return requestedCapabilities; } - public GLCapabilities getChosenGLCapabilities() { + public NWCapabilities getChosenNWCapabilities() { if (chosenCapabilities == null) return null; // Must return a new copy to avoid mutation by end user - return (GLCapabilities) chosenCapabilities.clone(); + return (NWCapabilities) chosenCapabilities.clone(); } - protected void setChosenGLCapabilities(GLCapabilities caps) { - chosenCapabilities = (caps==null) ? null : (GLCapabilities) caps.clone(); + protected void setChosenNWCapabilities(NWCapabilities caps) { + chosenCapabilities = (caps==null) ? null : (NWCapabilities) caps.clone(); } public NativeWindow getNativeWindow() { @@ -99,7 +100,7 @@ public abstract class GLDrawableImpl implements GLDrawable { public void setRealized(boolean realized) { this.realized = realized; if(!realized) { - setChosenGLCapabilities(null); + setChosenNWCapabilities(null); component.invalidate(); } } @@ -140,7 +141,7 @@ public abstract class GLDrawableImpl implements GLDrawable { protected GLDrawableFactory factory; protected NativeWindow component; - private GLCapabilities chosenCapabilities; + private NWCapabilities chosenCapabilities; // Indicates whether the component (if an onscreen context) has been // realized. Plausibly, before the component is realized the JAWT |