[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
hyatt at apple.com
hyatt at apple.com
Wed Dec 22 13:35:02 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 71676fce9cd07bef0d460dac820766059b1791d1
Author: hyatt at apple.com <hyatt at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Mon Sep 20 22:35:44 2010 +0000
https://bugs.webkit.org/show_bug.cgi?id=46126, add availableLogicalWidth() to RenderBox.
Reviewed by Dan Bernstein.
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::availableWidth):
(WebCore::RenderBlock::availableLogicalWidth):
* rendering/RenderBlock.h:
* rendering/RenderBox.cpp:
(WebCore::RenderBox::availableLogicalWidth):
* rendering/RenderBox.h:
(WebCore::RenderBox::availableWidth):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@67886 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index f1c0532..d8f8fab 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,18 @@
+2010-09-20 David Hyatt <hyatt at apple.com>
+
+ Reviewed by Dan Bernstein.
+
+ https://bugs.webkit.org/show_bug.cgi?id=46126, add availableLogicalWidth() to RenderBox.
+
+ * rendering/RenderBlock.cpp:
+ (WebCore::RenderBlock::availableWidth):
+ (WebCore::RenderBlock::availableLogicalWidth):
+ * rendering/RenderBlock.h:
+ * rendering/RenderBox.cpp:
+ (WebCore::RenderBox::availableLogicalWidth):
+ * rendering/RenderBox.h:
+ (WebCore::RenderBox::availableWidth):
+
2010-09-20 Kenneth Russell <kbr at google.com>
Reviewed by James Robinson.
diff --git a/WebCore/rendering/RenderBlock.cpp b/WebCore/rendering/RenderBlock.cpp
index 2f19e4b..60e1b6e 100644
--- a/WebCore/rendering/RenderBlock.cpp
+++ b/WebCore/rendering/RenderBlock.cpp
@@ -4305,7 +4305,15 @@ int RenderBlock::availableWidth() const
// If we have multiple columns, then the available width is reduced to our column width.
if (hasColumns())
return desiredColumnWidth();
- return contentWidth();
+ return RenderBox::availableWidth();
+}
+
+int RenderBlock::availableLogicalWidth() const
+{
+ // If we have multiple columns, then the available logical width is reduced to our column width.
+ if (hasColumns())
+ return desiredColumnWidth();
+ return RenderBox::availableLogicalWidth();
}
int RenderBlock::columnGap() const
diff --git a/WebCore/rendering/RenderBlock.h b/WebCore/rendering/RenderBlock.h
index fdfd021..b26c28c 100644
--- a/WebCore/rendering/RenderBlock.h
+++ b/WebCore/rendering/RenderBlock.h
@@ -114,8 +114,9 @@ public:
virtual VisiblePosition positionForPoint(const IntPoint&);
// Block flows subclass availableWidth to handle multi column layout (shrinking the width available to children when laying out.)
- virtual int availableWidth() const;
-
+ virtual int availableWidth() const; // FIXME: Should be possible to remove this. See https://bugs.webkit.org/show_bug.cgi?id=46127
+ virtual int availableLogicalWidth() const;
+
RootInlineBox* firstRootBox() const { return static_cast<RootInlineBox*>(firstLineBox()); }
RootInlineBox* lastRootBox() const { return static_cast<RootInlineBox*>(lastLineBox()); }
diff --git a/WebCore/rendering/RenderBox.cpp b/WebCore/rendering/RenderBox.cpp
index 58b150a..4e8eec3 100644
--- a/WebCore/rendering/RenderBox.cpp
+++ b/WebCore/rendering/RenderBox.cpp
@@ -1734,6 +1734,13 @@ int RenderBox::availableHeightUsing(const Length& h) const
return containingBlock()->availableHeight();
}
+int RenderBox::availableLogicalWidth() const
+{
+ if (style()->blockFlow() == TopToBottomBlockFlow || style()->blockFlow() == BottomToTopBlockFlow)
+ return contentWidth();
+ return contentHeight();
+}
+
void RenderBox::calcVerticalMargins()
{
if (isTableCell()) {
diff --git a/WebCore/rendering/RenderBox.h b/WebCore/rendering/RenderBox.h
index 0846708..476bcf9 100644
--- a/WebCore/rendering/RenderBox.h
+++ b/WebCore/rendering/RenderBox.h
@@ -238,9 +238,10 @@ public:
int calcPercentageHeight(const Length& height);
// Block flows subclass availableWidth to handle multi column layout (shrinking the width available to children when laying out.)
- virtual int availableWidth() const { return contentWidth(); }
+ virtual int availableWidth() const { return contentWidth(); } // FIXME: Investigate removing eventually. https://bugs.webkit.org/show_bug.cgi?id=46127
virtual int availableHeight() const;
int availableHeightUsing(const Length&) const;
+ virtual int availableLogicalWidth() const;
void calcVerticalMargins();
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list