diff options
Diffstat (limited to 'WebCore/editing/visible_units.cpp')
-rw-r--r-- | WebCore/editing/visible_units.cpp | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/WebCore/editing/visible_units.cpp b/WebCore/editing/visible_units.cpp index c96fdfd..84ace83 100644 --- a/WebCore/editing/visible_units.cpp +++ b/WebCore/editing/visible_units.cpp @@ -776,12 +776,6 @@ VisiblePosition nextSentencePosition(const VisiblePosition &c) return c.honorEditableBoundaryAtOrBefore(next); } -static bool renderedAsNonInlineTableOrHR(RenderObject* renderer) -{ - return renderer && ((renderer->isTable() && !renderer->isInline()) || renderer->isHR()); -} - -// FIXME: Broken for positions before/after images that aren't inline (5027702) VisiblePosition startOfParagraph(const VisiblePosition& c) { Position p = c.deepEquivalent(); @@ -790,7 +784,7 @@ VisiblePosition startOfParagraph(const VisiblePosition& c) if (!startNode) return VisiblePosition(); - if (renderedAsNonInlineTableOrHR(startNode->renderer()) && p.atLastEditingPositionForNode()) + if (isRenderedAsNonInlineTableImageOrHR(startNode)) return firstDeepEditingPositionForNode(startNode); Node* startBlock = enclosingBlock(startNode); @@ -841,7 +835,6 @@ VisiblePosition startOfParagraph(const VisiblePosition& c) return VisiblePosition(node, offset, DOWNSTREAM); } -// FIXME: Broken for positions before/after images that aren't inline (5027702) VisiblePosition endOfParagraph(const VisiblePosition &c) { if (c.isNull()) @@ -850,7 +843,7 @@ VisiblePosition endOfParagraph(const VisiblePosition &c) Position p = c.deepEquivalent(); Node* startNode = p.node(); - if (renderedAsNonInlineTableOrHR(startNode->renderer()) && p.atFirstEditingPositionForNode()) + if (isRenderedAsNonInlineTableImageOrHR(startNode)) return lastDeepEditingPositionForNode(startNode); Node* startBlock = enclosingBlock(startNode); |