Bug 1292545 - Don't skip clearing the canvas because of W(1) failures on Mac.
--- a/dom/canvas/CanvasRenderingContext2D.cpp
+++ b/dom/canvas/CanvasRenderingContext2D.cpp
@@ -1626,21 +1626,17 @@ CanvasRenderingContext2D::EnsureTarget(c
}
gCanvasAzureMemoryUsed += mWidth * mHeight * 4;
JSContext* context = nsContentUtils::GetCurrentJSContext();
if (context) {
JS_updateMallocCounter(context, mWidth * mHeight * 4);
}
- // Skia with the BGRX format requires the unused alpha channel (X) to be zero.
- bool isOpaqueSkia = mOpaque && mTarget->GetBackendType() == BackendType::SKIA;
- if (!canDiscardContent || isOpaqueSkia) {
- mTarget->ClearRect(canvasRect);
- }
+ mTarget->ClearRect(canvasRect);
// Force a full layer transaction since we didn't have a layer before
// and now we might need one.
if (mCanvasElement) {
mCanvasElement->InvalidateCanvas();
}
// Calling Redraw() tells our invalidation machinery that the entire
// canvas is already invalid, which can speed up future drawing.