Title: [111613] trunk/Source/WebCore
- Revision
- 111613
- Author
- [email protected]
- Date
- 2012-03-21 15:42:25 -0700 (Wed, 21 Mar 2012)
Log Message
Correct LayoutUnit usage in VisiblePosition.cpp
https://bugs.webkit.org/show_bug.cgi?id=81775
Reviewed by Eric Seidel.
Correcting a mismatch between the .h and .cpp for the definition of localCaretRect,
and properly using LayoutUnits for local coordinates.
No new tests. No change in behavior.
* editing/VisiblePosition.cpp:
(WebCore::VisiblePosition::localCaretRect): Switching to return a LayoutRect, as in the
header. Local coordinates are in LayoutUnits.
(WebCore::VisiblePosition::absoluteCaretBounds): Using LayoutRect for the localCaretRect.
(WebCore::VisiblePosition::lineDirectionPointForBlockDirectionNavigation): Ditto.
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (111612 => 111613)
--- trunk/Source/WebCore/ChangeLog 2012-03-21 22:39:11 UTC (rev 111612)
+++ trunk/Source/WebCore/ChangeLog 2012-03-21 22:42:25 UTC (rev 111613)
@@ -1,3 +1,21 @@
+2012-03-21 Levi Weintraub <[email protected]>
+
+ Correct LayoutUnit usage in VisiblePosition.cpp
+ https://bugs.webkit.org/show_bug.cgi?id=81775
+
+ Reviewed by Eric Seidel.
+
+ Correcting a mismatch between the .h and .cpp for the definition of localCaretRect,
+ and properly using LayoutUnits for local coordinates.
+
+ No new tests. No change in behavior.
+
+ * editing/VisiblePosition.cpp:
+ (WebCore::VisiblePosition::localCaretRect): Switching to return a LayoutRect, as in the
+ header. Local coordinates are in LayoutUnits.
+ (WebCore::VisiblePosition::absoluteCaretBounds): Using LayoutRect for the localCaretRect.
+ (WebCore::VisiblePosition::lineDirectionPointForBlockDirectionNavigation): Ditto.
+
2012-03-21 Adam Klein <[email protected]>
"this" argument for MutationCallbacks should be the MutationObserver
Modified: trunk/Source/WebCore/editing/VisiblePosition.cpp (111612 => 111613)
--- trunk/Source/WebCore/editing/VisiblePosition.cpp 2012-03-21 22:39:11 UTC (rev 111612)
+++ trunk/Source/WebCore/editing/VisiblePosition.cpp 2012-03-21 22:42:25 UTC (rev 111613)
@@ -595,7 +595,7 @@
return ch;
}
-IntRect VisiblePosition::localCaretRect(RenderObject*& renderer) const
+LayoutRect VisiblePosition::localCaretRect(RenderObject*& renderer) const
{
if (m_deepPosition.isNull()) {
renderer = 0;
@@ -605,7 +605,7 @@
renderer = node->renderer();
if (!renderer)
- return IntRect();
+ return LayoutRect();
InlineBox* inlineBox;
int caretOffset;
@@ -620,7 +620,7 @@
IntRect VisiblePosition::absoluteCaretBounds() const
{
RenderObject* renderer;
- IntRect localRect = localCaretRect(renderer);
+ LayoutRect localRect = localCaretRect(renderer);
if (localRect.isEmpty() || !renderer)
return IntRect();
@@ -630,7 +630,7 @@
int VisiblePosition::lineDirectionPointForBlockDirectionNavigation() const
{
RenderObject* renderer;
- IntRect localRect = localCaretRect(renderer);
+ LayoutRect localRect = localCaretRect(renderer);
if (localRect.isEmpty() || !renderer)
return 0;
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes