check if LockGL was called, before actually going on with UnlockGL
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28753 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -84,7 +84,9 @@ BGLView::LockGL()
|
|||||||
{
|
{
|
||||||
// TODO: acquire the OpenGL API lock it on this glview
|
// TODO: acquire the OpenGL API lock it on this glview
|
||||||
|
|
||||||
LockLooper();
|
if (!LockLooper())
|
||||||
|
return;
|
||||||
|
fDisplayLock.Lock();
|
||||||
if (fRenderer)
|
if (fRenderer)
|
||||||
fRenderer->LockGL();
|
fRenderer->LockGL();
|
||||||
}
|
}
|
||||||
@@ -93,6 +95,9 @@ BGLView::LockGL()
|
|||||||
void
|
void
|
||||||
BGLView::UnlockGL()
|
BGLView::UnlockGL()
|
||||||
{
|
{
|
||||||
|
if (!fDisplayLock.IsLocked())
|
||||||
|
return;
|
||||||
|
fDisplayLock.Unlock();
|
||||||
if (fRenderer)
|
if (fRenderer)
|
||||||
fRenderer->UnlockGL();
|
fRenderer->UnlockGL();
|
||||||
UnlockLooper();
|
UnlockLooper();
|
||||||
|
|||||||
Reference in New Issue
Block a user