[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
hyatt
hyatt at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:02:45 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit 516fa39b63f72e73f65762df6350a6f6e17c99e4
Author: hyatt <hyatt at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Sat Oct 18 20:48:27 2003 +0000
Fix for diveintomark className parsing bug. class="bigblue blue" would fail to match a rule with .blue.
The bug was in the selector matching code for class attributes.
Also fixing a minmax width bug for blocks on the mozilla.org Web site. XUL boxes had the same bug as
well.
Reviewed by darin
* khtml/css/cssstyleselector.cpp:
(khtml::CSSStyleSelector::checkOneSelector):
* khtml/rendering/render_block.cpp:
(khtml::RenderBlock::calcMinMaxWidth):
* khtml/rendering/render_flexbox.cpp:
(khtml::RenderFlexibleBox::calcMinMaxWidth):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@5205 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 555c54d..47dc121 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,5 +1,22 @@
2003-10-18 David Hyatt <hyatt at apple.com>
+ Fix for diveintomark className parsing bug. class="bigblue blue" would fail to match a rule with .blue.
+ The bug was in the selector matching code for class attributes.
+
+ Also fixing a minmax width bug for blocks on the mozilla.org Web site. XUL boxes had the same bug as
+ well.
+
+ Reviewed by darin
+
+ * khtml/css/cssstyleselector.cpp:
+ (khtml::CSSStyleSelector::checkOneSelector):
+ * khtml/rendering/render_block.cpp:
+ (khtml::RenderBlock::calcMinMaxWidth):
+ * khtml/rendering/render_flexbox.cpp:
+ (khtml::RenderFlexibleBox::calcMinMaxWidth):
+
+2003-10-18 David Hyatt <hyatt at apple.com>
+
Fix for 3443502, generated content sometimes doesn't generate. The bug is caused by an
uninitialized variable. m_isContinuation needed to be set to false in the RenderInline
constructor.
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 555c54d..47dc121 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,5 +1,22 @@
2003-10-18 David Hyatt <hyatt at apple.com>
+ Fix for diveintomark className parsing bug. class="bigblue blue" would fail to match a rule with .blue.
+ The bug was in the selector matching code for class attributes.
+
+ Also fixing a minmax width bug for blocks on the mozilla.org Web site. XUL boxes had the same bug as
+ well.
+
+ Reviewed by darin
+
+ * khtml/css/cssstyleselector.cpp:
+ (khtml::CSSStyleSelector::checkOneSelector):
+ * khtml/rendering/render_block.cpp:
+ (khtml::RenderBlock::calcMinMaxWidth):
+ * khtml/rendering/render_flexbox.cpp:
+ (khtml::RenderFlexibleBox::calcMinMaxWidth):
+
+2003-10-18 David Hyatt <hyatt at apple.com>
+
Fix for 3443502, generated content sometimes doesn't generate. The bug is caused by an
uninitialized variable. m_isContinuation needed to be set to false in the RenderInline
constructor.
diff --git a/WebCore/khtml/css/cssstyleselector.cpp b/WebCore/khtml/css/cssstyleselector.cpp
index 730a70d..8d8ffa9 100644
--- a/WebCore/khtml/css/cssstyleselector.cpp
+++ b/WebCore/khtml/css/cssstyleselector.cpp
@@ -843,11 +843,20 @@ bool CSSStyleSelector::checkOneSelector(DOM::CSSSelector *sel, DOM::ElementImpl
QString str = value.string();
QString selStr = sel->value.string();
- int pos = str.find(selStr, 0, isXMLDoc);
- if(pos == -1) return false;
- if(pos && str[pos-1] != ' ') return false;
- pos += selStr.length();
- if(pos < (int)str.length() && str[pos] != ' ') return false;
+ int startSearchAt = 0;
+ while (true) {
+ int foundPos = str.find(selStr, startSearchAt, isXMLDoc);
+ if (foundPos == -1) return false;
+ if (foundPos == 0 || str[foundPos-1] == ' ') {
+ uint endStr = foundPos + selStr.length();
+ if (endStr == str.length() || str[endStr] == ' ')
+ break; // We found a match.
+ }
+
+ // No match. Keep looking.
+ startSearchAt = foundPos + 1;
+ }
+
break;
}
case CSSSelector::Contain:
diff --git a/WebCore/khtml/rendering/render_block.cpp b/WebCore/khtml/rendering/render_block.cpp
index e3d0145..602dd1a 100644
--- a/WebCore/khtml/rendering/render_block.cpp
+++ b/WebCore/khtml/rendering/render_block.cpp
@@ -1980,11 +1980,11 @@ void RenderBlock::calcMinMaxWidth()
m_minWidth = m_maxWidth;
if (style()->width().isFixed() && style()->width().value > 0) {
- m_maxWidth = KMAX(m_minWidth,short(style()->width().value));
- if (!isTableCell())
- m_minWidth = m_maxWidth;
+ if (isTableCell())
+ m_maxWidth = KMAX(m_minWidth,short(style()->width().value));
+ else
+ m_minWidth = m_maxWidth = short(style()->width().value);
}
- // FIXME: also compare with min/max width CSS properties...
int toAdd = 0;
toAdd = borderLeft() + borderRight() + paddingLeft() + paddingRight();
@@ -1992,14 +1992,6 @@ void RenderBlock::calcMinMaxWidth()
m_minWidth += toAdd;
m_maxWidth += toAdd;
- // Scrolling marquees like to use this trick:
- // <td><div style="overflow:hidden; width:300px"><nobr>.....[lots of text].....</nobr></div></td>
- // We need to sanity-check our m_minWidth, and not let it exceed our clipped boundary. -dwh
- // FIXME: For now, punt on trying to apply this fix to table cells. We don't know an accurate
- // width for the cell here, so we can't do a comparison.
- if (style()->hidesOverflow() && m_minWidth > m_width && !isTableCell())
- m_minWidth = m_width;
-
setMinMaxKnown();
//kdDebug( 6040 ) << "Text::calcMinMaxWidth(" << this << "): min = " << m_minWidth << " max = " << m_maxWidth << endl;
diff --git a/WebCore/khtml/rendering/render_flexbox.cpp b/WebCore/khtml/rendering/render_flexbox.cpp
index 0c93db7..ac44249 100644
--- a/WebCore/khtml/rendering/render_flexbox.cpp
+++ b/WebCore/khtml/rendering/render_flexbox.cpp
@@ -219,19 +219,12 @@ void RenderFlexibleBox::calcMinMaxWidth()
if(m_maxWidth < m_minWidth) m_maxWidth = m_minWidth;
if (style()->width().isFixed() && style()->width().value > 0)
- m_minWidth = m_maxWidth = KMAX(m_minWidth,short(style()->width().value));
- // FIXME: also compare with min/max width CSS properties...
+ m_minWidth = m_maxWidth = short(style()->width().value);
int toAdd = borderLeft() + borderRight() + paddingLeft() + paddingRight();
m_minWidth += toAdd;
m_maxWidth += toAdd;
- // Scrolling marquees like to use this trick:
- // <td><div style="overflow:hidden; width:300px"><nobr>.....[lots of text].....</nobr></div></td>
- // We need to sanity-check our m_minWidth, and not let it exceed our clipped boundary.
- if (style()->hidesOverflow() && m_minWidth > m_width)
- m_minWidth = m_width;
-
setMinMaxKnown();
}
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list