Commit f5fc941d authored by hyatt's avatar hyatt
Browse files

Half of a fix for 13793, make sure rules=groups and border behave properly

        together.

        Reviewed by mitz

        No tests added, two Mozilla table tests now pass that failed before.

        * html/HTMLTableElement.cpp:
        (WebCore::HTMLTableElement::getSharedCellDecl):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@21614 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent a17d2ac0
2007-05-20 David Hyatt <hyatt@apple.com>
Half of a fix for 13793, make sure rules=groups and border behave properly
together.
Reviewed by mitz
No tests added, two Mozilla table tests now pass that failed before.
* html/HTMLTableElement.cpp:
(WebCore::HTMLTableElement::getSharedCellDecl):
2007-05-20 Brady Eidson <beidson@apple.com>
 
Reviewed by Geoose Garen
......@@ -526,7 +526,7 @@ CSSMutableStyleDeclaration* HTMLTableElement::getSharedCellDecl()
{
MappedAttribute attr(cellborderAttr, m_rulesAttr == AllRules ? "solid-all" :
(m_rulesAttr == ColsRules ? "solid-cols" :
(m_rulesAttr == RowsRules ? "solid-rows" : (!m_borderAttr ? "none" : (m_borderColorAttr ? "solid" : "inset")))));
(m_rulesAttr == RowsRules ? "solid-rows" : (!m_borderAttr || m_rulesAttr == GroupsRules ? "none" : (m_borderColorAttr ? "solid" : "inset")))));
CSSMappedAttributeDeclaration* decl = getMappedAttributeDecl(ePersistent, &attr);
if (!decl) {
......@@ -549,7 +549,7 @@ CSSMutableStyleDeclaration* HTMLTableElement::getSharedCellDecl()
decl->setProperty(CSS_PROP_BORDER_TOP_STYLE, CSS_VAL_SOLID, false);
decl->setProperty(CSS_PROP_BORDER_BOTTOM_STYLE, CSS_VAL_SOLID, false);
decl->setProperty(CSS_PROP_BORDER_COLOR, "inherit", false);
} else if (m_borderAttr || m_rulesAttr == AllRules) {
} else if (m_rulesAttr != GroupsRules && (m_borderAttr || m_rulesAttr == AllRules)) {
decl->setProperty(CSS_PROP_BORDER_WIDTH, "1px", false);
int v = (m_borderColorAttr || m_rulesAttr == AllRules) ? CSS_VAL_SOLID : CSS_VAL_INSET;
decl->setProperty(CSS_PROP_BORDER_TOP_STYLE, v, false);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment