diff options
author | Kenneth Russel <[email protected]> | 2005-11-14 20:40:27 +0000 |
---|---|---|
committer | Kenneth Russel <[email protected]> | 2005-11-14 20:40:27 +0000 |
commit | ad056ab1c455a0be99d83e2e50d5826e98c1f5d5 (patch) | |
tree | 0f87ef9aa3d31ed8d8e106e2e4777206849afc27 /src/classes/com/sun/opengl/impl | |
parent | b81f433446e36815a2dfe9b9e42f516d5a4a9e9b (diff) |
Deleted unnecessary references to AWT Component in base GLDrawable
classes on Windows and X11 platforms
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@449 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/classes/com/sun/opengl/impl')
11 files changed, 17 insertions, 23 deletions
diff --git a/src/classes/com/sun/opengl/impl/windows/WindowsDummyGLDrawable.java b/src/classes/com/sun/opengl/impl/windows/WindowsDummyGLDrawable.java index d57ddec2a..e4d4d26d0 100644 --- a/src/classes/com/sun/opengl/impl/windows/WindowsDummyGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/windows/WindowsDummyGLDrawable.java @@ -46,7 +46,7 @@ public class WindowsDummyGLDrawable extends WindowsGLDrawable { private long hwnd; public WindowsDummyGLDrawable() { - super(null, new GLCapabilities(), null); + super(new GLCapabilities(), null); // All entries to CreateDummyWindow must synchronize on one object // to avoid accidentally registering the dummy window class twice synchronized (WindowsDummyGLDrawable.class) { diff --git a/src/classes/com/sun/opengl/impl/windows/WindowsExternalGLDrawable.java b/src/classes/com/sun/opengl/impl/windows/WindowsExternalGLDrawable.java index f934c1d23..68ab83161 100755 --- a/src/classes/com/sun/opengl/impl/windows/WindowsExternalGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/windows/WindowsExternalGLDrawable.java @@ -44,7 +44,7 @@ import com.sun.opengl.impl.*; public class WindowsExternalGLDrawable extends WindowsGLDrawable { public WindowsExternalGLDrawable() { - super(null, new GLCapabilities(), null); + super(new GLCapabilities(), null); hdc = WGL.wglGetCurrentDC(); } diff --git a/src/classes/com/sun/opengl/impl/windows/WindowsGLDrawable.java b/src/classes/com/sun/opengl/impl/windows/WindowsGLDrawable.java index 1b870d391..b4e059b72 100644 --- a/src/classes/com/sun/opengl/impl/windows/WindowsGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/windows/WindowsGLDrawable.java @@ -39,10 +39,6 @@ package com.sun.opengl.impl.windows; -import java.awt.Component; -import java.awt.GraphicsConfiguration; -import java.awt.GraphicsDevice; - import javax.media.opengl.*; import com.sun.opengl.impl.*; @@ -50,7 +46,6 @@ public abstract class WindowsGLDrawable extends GLDrawableImpl { protected static final boolean DEBUG = Debug.debug("WindowsGLDrawable"); protected long hdc; - protected Component component; protected GLCapabilities capabilities; protected GLCapabilitiesChooser chooser; protected boolean pixelFormatChosen; @@ -58,10 +53,8 @@ public abstract class WindowsGLDrawable extends GLDrawableImpl { protected static final int MAX_PFORMATS = 256; protected static final int MAX_ATTRIBS = 256; - public WindowsGLDrawable(Component component, - GLCapabilities capabilities, + public WindowsGLDrawable(GLCapabilities capabilities, GLCapabilitiesChooser chooser) { - this.component = component; this.capabilities = (GLCapabilities) capabilities.clone(); this.chooser = chooser; } diff --git a/src/classes/com/sun/opengl/impl/windows/WindowsOffscreenGLDrawable.java b/src/classes/com/sun/opengl/impl/windows/WindowsOffscreenGLDrawable.java index a128ea1a4..4fe9c93b2 100644 --- a/src/classes/com/sun/opengl/impl/windows/WindowsOffscreenGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/windows/WindowsOffscreenGLDrawable.java @@ -51,7 +51,7 @@ public class WindowsOffscreenGLDrawable extends WindowsGLDrawable { public WindowsOffscreenGLDrawable(GLCapabilities capabilities, GLCapabilitiesChooser chooser) { - super(null, capabilities, chooser); + super(capabilities, chooser); } public GLContext createContext(GLContext shareWith) { diff --git a/src/classes/com/sun/opengl/impl/windows/WindowsOnscreenGLDrawable.java b/src/classes/com/sun/opengl/impl/windows/WindowsOnscreenGLDrawable.java index c475e1d0a..bc21c58b7 100644 --- a/src/classes/com/sun/opengl/impl/windows/WindowsOnscreenGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/windows/WindowsOnscreenGLDrawable.java @@ -49,6 +49,8 @@ public class WindowsOnscreenGLDrawable extends WindowsGLDrawable { public static final int LOCK_SURFACE_CHANGED = 2; public static final int LOCK_SUCCESS = 3; + protected Component component; + // Variables for lockSurface/unlockSurface private JAWT_DrawingSurface ds; private JAWT_DrawingSurfaceInfo dsi; @@ -69,7 +71,8 @@ public class WindowsOnscreenGLDrawable extends WindowsGLDrawable { public WindowsOnscreenGLDrawable(Component component, GLCapabilities capabilities, GLCapabilitiesChooser chooser) { - super(component, capabilities, chooser); + super(capabilities, chooser); + this.component = component; } public GLContext createContext(GLContext shareWith) { diff --git a/src/classes/com/sun/opengl/impl/windows/WindowsPbufferGLDrawable.java b/src/classes/com/sun/opengl/impl/windows/WindowsPbufferGLDrawable.java index 8e660cc51..3874edfd6 100644 --- a/src/classes/com/sun/opengl/impl/windows/WindowsPbufferGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/windows/WindowsPbufferGLDrawable.java @@ -59,7 +59,7 @@ public class WindowsPbufferGLDrawable extends WindowsGLDrawable { int initialHeight, WindowsGLDrawable dummyDrawable, WGLExt wglExt) { - super(null, capabilities, null); + super(capabilities, null); this.initWidth = initialWidth; this.initHeight = initialHeight; if (initWidth <= 0 || initHeight <= 0) { diff --git a/src/classes/com/sun/opengl/impl/x11/X11ExternalGLDrawable.java b/src/classes/com/sun/opengl/impl/x11/X11ExternalGLDrawable.java index 96e1d0034..e8fc069ba 100755 --- a/src/classes/com/sun/opengl/impl/x11/X11ExternalGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/x11/X11ExternalGLDrawable.java @@ -49,7 +49,7 @@ public class X11ExternalGLDrawable extends X11GLDrawable { private long readDrawable; public X11ExternalGLDrawable() { - super(null, null, null); + super(null, null); lockToolkit(); try { display = GLX.glXGetCurrentDisplay(); diff --git a/src/classes/com/sun/opengl/impl/x11/X11GLDrawable.java b/src/classes/com/sun/opengl/impl/x11/X11GLDrawable.java index 6395bbce8..61d4a70f5 100644 --- a/src/classes/com/sun/opengl/impl/x11/X11GLDrawable.java +++ b/src/classes/com/sun/opengl/impl/x11/X11GLDrawable.java @@ -39,8 +39,6 @@ package com.sun.opengl.impl.x11; -import java.awt.Component; - import javax.media.opengl.*; import com.sun.opengl.impl.*; @@ -50,14 +48,11 @@ public abstract class X11GLDrawable extends GLDrawableImpl { protected long display; protected long drawable; protected long visualID; - protected Component component; protected GLCapabilities capabilities; protected GLCapabilitiesChooser chooser; - public X11GLDrawable(Component component, - GLCapabilities capabilities, + public X11GLDrawable(GLCapabilities capabilities, GLCapabilitiesChooser chooser) { - this.component = component; this.capabilities = (capabilities == null) ? null : ((GLCapabilities) capabilities.clone()); this.chooser = chooser; diff --git a/src/classes/com/sun/opengl/impl/x11/X11OffscreenGLDrawable.java b/src/classes/com/sun/opengl/impl/x11/X11OffscreenGLDrawable.java index 5370860c6..3b3879b8e 100644 --- a/src/classes/com/sun/opengl/impl/x11/X11OffscreenGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/x11/X11OffscreenGLDrawable.java @@ -51,7 +51,7 @@ public class X11OffscreenGLDrawable extends X11GLDrawable { public X11OffscreenGLDrawable(GLCapabilities capabilities, GLCapabilitiesChooser chooser) { - super(null, capabilities, chooser); + super(capabilities, chooser); } public GLContext createContext(GLContext shareWith) { diff --git a/src/classes/com/sun/opengl/impl/x11/X11OnscreenGLDrawable.java b/src/classes/com/sun/opengl/impl/x11/X11OnscreenGLDrawable.java index 810de42c5..b1a3ebac7 100644 --- a/src/classes/com/sun/opengl/impl/x11/X11OnscreenGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/x11/X11OnscreenGLDrawable.java @@ -49,6 +49,8 @@ public class X11OnscreenGLDrawable extends X11GLDrawable { public static final int LOCK_SURFACE_CHANGED = 2; public static final int LOCK_SUCCESS = 3; + protected Component component; + // Variables for lockSurface/unlockSurface private JAWT_DrawingSurface ds; private JAWT_DrawingSurfaceInfo dsi; @@ -67,7 +69,8 @@ public class X11OnscreenGLDrawable extends X11GLDrawable { protected boolean realized; public X11OnscreenGLDrawable(Component component) { - super(component, null, null); + super(null, null); + this.component = component; } public GLContext createContext(GLContext shareWith) { diff --git a/src/classes/com/sun/opengl/impl/x11/X11PbufferGLDrawable.java b/src/classes/com/sun/opengl/impl/x11/X11PbufferGLDrawable.java index 85df39267..eddc5c14d 100644 --- a/src/classes/com/sun/opengl/impl/x11/X11PbufferGLDrawable.java +++ b/src/classes/com/sun/opengl/impl/x11/X11PbufferGLDrawable.java @@ -55,7 +55,7 @@ public class X11PbufferGLDrawable extends X11GLDrawable { protected static final int MAX_ATTRIBS = 256; public X11PbufferGLDrawable(GLCapabilities capabilities, int initialWidth, int initialHeight) { - super(null, capabilities, null); + super(capabilities, null); this.initWidth = initialWidth; this.initHeight = initialHeight; if (initWidth <= 0 || initHeight <= 0) { |