[Webkit-unassigned] [Bug 42799] pixelWidth/posWidth are processed incorrectly

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Sep 25 22:33:21 PDT 2010


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





--- Comment #15 from Yuxiang Luo <luoyx at google.com>  2010-09-25 22:33:20 PST ---
(In reply to comment #14)
> (In reply to comment #13)
> > Thanks very much for the review. Do you mean the handling of pixel/pos should be put in CSSStyleDeclaration class? However, I don't think it should be put there, because pixel/pos-prefix properties are not CSS property, but CSSOM property accessed by script. And, if we put the logic in there, when setting 'pixelWidth', the CSSStyleDeclaration::setProperty will be invoked as following:
> >   setProperty('width', PREFIX_PIXEL, 100, ...);
> > The interface then looks very weird, people don't know what the interface intends to do.
> > 
> > Isn't it better to let CSSStyleDeclaration do only what it should do, that is to get/set primitive css properties? It might be better to put transformation code between primitive css properties and cssom properties in bindings.
> 
> Yes, we should put it on CSSStyleDeclaration. If you don’t like having that code in CSSStyleDeclaration we can just call over to Element and put the bulk of the work in that class.

But such properties belong to Style object, not Element/Node. Logically, such CSSOM properties should belong to bindings object (i.e. JSCSSStyleDeclaration), although it makes the logic in it more complex.

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