aboutsummaryrefslogtreecommitdiffstats
path: root/src/native/jogl/MacOSXWindowSystemInterface.m
diff options
context:
space:
mode:
authorKenneth Russel <[email protected]>2005-05-10 17:47:31 +0000
committerKenneth Russel <[email protected]>2005-05-10 17:47:31 +0000
commit7da326380ca234d31627c5eaa8e7eacd3bfb8a4d (patch)
tree0a827c1e1384f9b36e01fb314d9ee182bcfa23a2 /src/native/jogl/MacOSXWindowSystemInterface.m
parentff22a4f5a17eac8402706993dd54f75b6fae0110 (diff)
Fixed race conditions in Mac OS X onscreen context creation that
showed up after recent GLJPanel fix to clean up resource leaks. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@267 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/native/jogl/MacOSXWindowSystemInterface.m')
-rw-r--r--src/native/jogl/MacOSXWindowSystemInterface.m8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/native/jogl/MacOSXWindowSystemInterface.m b/src/native/jogl/MacOSXWindowSystemInterface.m
index 6a5969fff..46c50ceb7 100644
--- a/src/native/jogl/MacOSXWindowSystemInterface.m
+++ b/src/native/jogl/MacOSXWindowSystemInterface.m
@@ -29,7 +29,8 @@ void* createContext(void* shareContext, void* view,
int accumBlueBits,
int accumAlphaBits,
int sampleBuffers,
- int numSamples)
+ int numSamples,
+ int* viewNotReady)
{
int colorSize = redBits + greenBits + blueBits;
int accumSize = accumRedBits + accumGreenBits + accumBlueBits;
@@ -48,7 +49,10 @@ void* createContext(void* shareContext, void* view,
}
else if ([nsView lockFocusIfCanDraw] == NO)
{
- fprintf(stderr, "Error: view not ready, cannot lock focus at \"%s:%s:%d\"\n", __FILE__, __FUNCTION__, __LINE__);
+ if (viewNotReady != NULL) {
+ *viewNotReady = 1;
+ }
+
// the view is not ready yet
return NULL;
}