mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-05 07:18:39 +09:00
Issue #1354 - Clear the current context when MakeCurrent() fails.
This commit is contained in:
parent
8d600c51ed
commit
9d76eb5791
10 changed files with 81 additions and 95 deletions
|
|
@ -314,20 +314,17 @@ GLContextWGL::Init()
|
|||
if (!mDC || !mContext)
|
||||
return false;
|
||||
|
||||
// see bug 929506 comment 29. wglGetProcAddress requires a current context.
|
||||
if (!sWGLLib.fMakeCurrent(mDC, mContext))
|
||||
return false;
|
||||
|
||||
SetupLookupFunction();
|
||||
if (!InitWithPrefix("gl", true))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
return InitWithPrefix("gl", true);
|
||||
}
|
||||
|
||||
bool
|
||||
GLContextWGL::MakeCurrentImpl(bool aForce)
|
||||
{
|
||||
if (IsDestroyed()) {
|
||||
MOZ_ALWAYS_TRUE(sWGLLib.fMakeCurrent(0, 0));
|
||||
}
|
||||
|
||||
BOOL succeeded = true;
|
||||
|
||||
// wglGetCurrentContext seems to just pull the HGLRC out
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue