[Webkit-unassigned] [Bug 70304] width/height attributes of input element should be supported when the type of the input element is image.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Dec 1 23:21:43 PST 2011


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





--- Comment #39 from Dongwoo Joshua Im <dw.im at samsung.com>  2011-12-01 23:21:43 PST ---
(In reply to comment #38)
> (From update of attachment 117571 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=117571&action=review
> 
> > LayoutTests/fast/forms/input-width-height-attributes.html:54
> > +var div1 = document.getElementById("div1");
> 
> The variable div1 - div8 are not needed.
> 
Yes. we can remove div2 ~ div8.
We can remove image2 ~ image4, as well.

> > LayoutTests/fast/forms/input-width-height-attributes.html:86
> > +text1.width = 100;
> > +text1.height = 50;
> > +debug('Test case #5 : Text, Setting by JavaScript API as \"100\", \"50\"');
> > +shouldBe('text1.width,text1.height', '0,0');
> > +
> 
> After this, we had better test:
>  - text1 has width= and height= HTML attributes.
>  - Changing the type to image, width/height values are not changed.
> 
I will try.

> > Source/WebCore/html/InputType.cpp:753
> > +void InputType::setHeight(unsigned height)
> > +{
> > +    element()->setAttribute(heightAttr, String::number(height));
> > +}
> > +
> > +void InputType::setWidth(unsigned width)
> > +{
> > +    element()->setAttribute(widthAttr, String::number(width));
> > +}
> > +
> 
> No other *InputType overrides setHeight() and setWidth().  We can remove them and move the code to HTMLInputElement::setHeight()/setWidth().

Yes, you are right!

-- 
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