From 6bbf70d2f4a06b8aa0b100d83ed9aca6dd80040e Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Wed, 2 Jun 2010 16:49:28 +0200 Subject: JOGL: Sanity check in GLDrawableHelper (Context creation and initAction) ; Add Platform info in test --- src/jogl/classes/com/jogamp/opengl/impl/GLDrawableHelper.java | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/jogl') diff --git a/src/jogl/classes/com/jogamp/opengl/impl/GLDrawableHelper.java b/src/jogl/classes/com/jogamp/opengl/impl/GLDrawableHelper.java index 7a4e84081..fca0a7d93 100644 --- a/src/jogl/classes/com/jogamp/opengl/impl/GLDrawableHelper.java +++ b/src/jogl/classes/com/jogamp/opengl/impl/GLDrawableHelper.java @@ -136,6 +136,9 @@ public class GLDrawableHelper { lastContext.release(); } + if(!context.isCreated() && null == initAction) { + throw new GLException("Context has to be created, but no initAction is given: "+context); + } int res = 0; try { res = context.makeCurrent(); -- cgit v1.2.3