Advanced Dialog for CSS properties should rely on DOM Level 2 ElementCSSInlineStyle instead of parsing by hand the contents of the STYLE attribute.
Patch for this bug added above. I think it is much more reliable than the former parsing "by hand" of tokens separated by semi-colons. In particular, the value of a CSS property can be a string containing a semi-colon... r= and sr= needed, thanks.
r=cmanske Can you solve the problem that we have in Advanced editor that we always end up with separate CSS attributes (e.g.: border-left : 10px; border-right : 10px...) instead of combined (e.g. border : 10px)?
Hum. This is a very complex problem. 'border-width' is not really a property in itself but a shorthand setting the 4 values of border-left -right -bottom -top. I think that our CSS OM does not correctly support queries on shorthand properties for the moment and your problem is a side-effect of that one.
Question ... the old code: - var style = element.getAttribute("style"); returns a string and the new code: + var style = element.style; returns an object? Shouldn't we check if style is undefined before we try to access style.length? + var style = element.style; + var l = style.length; + + if(style == undefined || style == "" || l == 0)
Agreed ; will submit a rewriting tomorrow
patch re-submitted in answer to Kin. sr= ?
email@example.com with the changes we discussed over aim. (Remove dump statements where not neccessary.)
yay! checked in :-)
Glazman, can you verify this and mark verified-fixed? thanks!
glazman, please verify this one...thanks...
code level fix...marking verified.