mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-27 04:05:32 +00:00
Bug 629870 - Drop support for globalCompositeOperation=over,clear; r=sicking
This commit is contained in:
parent
86e18547a1
commit
63b9ab3636
@ -3457,8 +3457,7 @@ nsCanvasRenderingContext2D::SetGlobalCompositeOperation(const nsAString& op)
|
||||
if (op.EqualsLiteral(cvsop)) \
|
||||
thebes_op = gfxContext::OPERATOR_##thebesop;
|
||||
|
||||
CANVAS_OP_TO_THEBES_OP("clear", CLEAR)
|
||||
else CANVAS_OP_TO_THEBES_OP("copy", SOURCE)
|
||||
CANVAS_OP_TO_THEBES_OP("copy", SOURCE)
|
||||
else CANVAS_OP_TO_THEBES_OP("destination-atop", DEST_ATOP)
|
||||
else CANVAS_OP_TO_THEBES_OP("destination-in", DEST_IN)
|
||||
else CANVAS_OP_TO_THEBES_OP("destination-out", DEST_OUT)
|
||||
@ -3469,8 +3468,6 @@ nsCanvasRenderingContext2D::SetGlobalCompositeOperation(const nsAString& op)
|
||||
else CANVAS_OP_TO_THEBES_OP("source-out", OUT)
|
||||
else CANVAS_OP_TO_THEBES_OP("source-over", OVER)
|
||||
else CANVAS_OP_TO_THEBES_OP("xor", XOR)
|
||||
// not part of spec, kept here for compat
|
||||
else CANVAS_OP_TO_THEBES_OP("over", OVER)
|
||||
// XXX ERRMSG we need to report an error to developers here! (bug 329026)
|
||||
else return NS_OK;
|
||||
|
||||
@ -3489,10 +3486,7 @@ nsCanvasRenderingContext2D::GetGlobalCompositeOperation(nsAString& op)
|
||||
if (thebes_op == gfxContext::OPERATOR_##thebesop) \
|
||||
op.AssignLiteral(cvsop);
|
||||
|
||||
// XXX "darker" isn't really correct
|
||||
CANVAS_OP_TO_THEBES_OP("clear", CLEAR)
|
||||
else CANVAS_OP_TO_THEBES_OP("copy", SOURCE)
|
||||
else CANVAS_OP_TO_THEBES_OP("darker", SATURATE) // XXX
|
||||
CANVAS_OP_TO_THEBES_OP("copy", SOURCE)
|
||||
else CANVAS_OP_TO_THEBES_OP("destination-atop", DEST_ATOP)
|
||||
else CANVAS_OP_TO_THEBES_OP("destination-in", DEST_IN)
|
||||
else CANVAS_OP_TO_THEBES_OP("destination-out", DEST_OUT)
|
||||
|
@ -1486,7 +1486,7 @@ var ctx = canvas.getContext('2d');
|
||||
|
||||
ctx.globalCompositeOperation = 'xor';
|
||||
ctx.globalCompositeOperation = 'clear';
|
||||
todo(ctx.globalCompositeOperation == 'xor', "ctx.globalCompositeOperation == 'xor'");
|
||||
ok(ctx.globalCompositeOperation == 'xor', "ctx.globalCompositeOperation == 'xor'");
|
||||
|
||||
|
||||
}
|
||||
@ -1619,7 +1619,7 @@ var ctx = canvas.getContext('2d');
|
||||
|
||||
ctx.globalCompositeOperation = 'xor';
|
||||
ctx.globalCompositeOperation = 'over';
|
||||
todo(ctx.globalCompositeOperation == 'xor', "ctx.globalCompositeOperation == 'xor'");
|
||||
ok(ctx.globalCompositeOperation == 'xor', "ctx.globalCompositeOperation == 'xor'");
|
||||
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user