[Webkit-unassigned] [Bug 39149] Canvas element cannot have negative width or height

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun May 16 00:39:35 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=39149


Eric Seidel <eric at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #56176|review?                     |review+
               Flag|                            |




--- Comment #4 from Eric Seidel <eric at webkit.org>  2010-05-16 00:39:34 PST ---
(From update of attachment 56176)
WebCore/html/HTMLCanvasElement.cpp:116
 +          setAttribute(heightAttr, String::number(DefaultHeight));
I would have probably used a ternary here.  Something like:
int height = (value >= 0) ? value : DefaultHeight);

Otherwise the code and test look great.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list