diff --git a/content/canvas/src/WebGLContext.cpp b/content/canvas/src/WebGLContext.cpp index c2fb656f5fe..9eceac232e7 100644 --- a/content/canvas/src/WebGLContext.cpp +++ b/content/canvas/src/WebGLContext.cpp @@ -318,23 +318,23 @@ WebGLContext::SetDimensions(PRInt32 width, PRInt32 height) PRBool useOpenGL = PR_TRUE; PRBool useANGLE = PR_TRUE; - nsCOMPtr gfxInfo = do_GetService("@mozilla.org/gfx/info;1"); - if (gfxInfo) { - PRInt32 status; - if (NS_SUCCEEDED(gfxInfo->GetFeatureStatus(nsIGfxInfo::FEATURE_WEBGL_OPENGL, &status))) { - if (status != nsIGfxInfo::FEATURE_STATUS_UNKNOWN && - status != nsIGfxInfo::FEATURE_AVAILABLE) - { - useOpenGL = PR_FALSE; - } - } - if (NS_SUCCEEDED(gfxInfo->GetFeatureStatus(nsIGfxInfo::FEATURE_WEBGL_ANGLE, &status))) { - if (status != nsIGfxInfo::FEATURE_STATUS_UNKNOWN && - status != nsIGfxInfo::FEATURE_AVAILABLE) - { - useANGLE = PR_FALSE; - } - } + nsCOMPtr gfxInfo = do_GetService("@mozilla.org/gfx/info;1"); + if (gfxInfo) { + PRInt32 status; + if (NS_SUCCEEDED(gfxInfo->GetFeatureStatus(nsIGfxInfo::FEATURE_WEBGL_OPENGL, &status))) { + if (status == nsIGfxInfo::FEATURE_BLOCKED || + status == nsIGfxInfo::FEATURE_NOT_AVAILABLE) + { + useOpenGL = PR_FALSE; + } + } + if (NS_SUCCEEDED(gfxInfo->GetFeatureStatus(nsIGfxInfo::FEATURE_WEBGL_ANGLE, &status))) { + if (status == nsIGfxInfo::FEATURE_BLOCKED || + status == nsIGfxInfo::FEATURE_NOT_AVAILABLE) + { + useANGLE = PR_FALSE; + } + } } #ifdef XP_WIN