Browse Source

Fixed SetShadowBlur()

v1.x
Tj Holowaychuk 14 years ago
parent
commit
6d75f5ab30
  1. 3
      src/CanvasRenderingContext2d.cc

3
src/CanvasRenderingContext2d.cc

@ -356,7 +356,7 @@ Context2d::GetShadowBlur(Local<String> prop, const AccessorInfo &info) {
void
Context2d::SetShadowBlur(Local<String> prop, Local<Value> val, const AccessorInfo &info) {
double n = val->NumberValue();
if (n > 0) {
if (n >= 0) {
Context2d *context = ObjectWrap::Unwrap<Context2d>(info.This());
context->state->shadowBlur = n;
}
@ -1043,7 +1043,6 @@ Context2d::FillRect(const Arguments &args) {
cairo_t *ctx = context->getContext();
cairo_new_path(ctx);
printf("%d\n", context->hasShadow());
if (!context->hasShadow()) {
cairo_rectangle(ctx, x, y, width, height);
SET_SOURCE(context->state->fill);

Loading…
Cancel
Save