Index: Source/WebCore/rendering/RenderView.cpp |
=================================================================== |
--- Source/WebCore/rendering/RenderView.cpp (revision 110458) |
+++ Source/WebCore/rendering/RenderView.cpp (working copy) |
@@ -487,7 +487,7 @@ |
// Now clear the selection. |
SelectedObjectMap::iterator oldObjectsEnd = oldSelectedObjects.end(); |
for (SelectedObjectMap::iterator i = oldSelectedObjects.begin(); i != oldObjectsEnd; ++i) |
- i->first->setSelectionState(SelectionNone); |
+ i->first->setSelectionStateIfNeeded(SelectionNone); |
// set selection start and end |
m_selectionStart = start; |
@@ -497,12 +497,12 @@ |
// Update the selection status of all objects between m_selectionStart and m_selectionEnd |
if (start && start == end) |
- start->setSelectionState(SelectionBoth); |
+ start->setSelectionStateIfNeeded(SelectionBoth); |
else { |
if (start) |
- start->setSelectionState(SelectionStart); |
+ start->setSelectionStateIfNeeded(SelectionStart); |
if (end) |
- end->setSelectionState(SelectionEnd); |
+ end->setSelectionStateIfNeeded(SelectionEnd); |
} |
RenderObject* o = start; |
@@ -510,7 +510,7 @@ |
while (o && o != stop) { |
if (o != start && o != end && o->canBeSelectionLeaf()) |
- o->setSelectionState(SelectionInside); |
+ o->setSelectionStateIfNeeded(SelectionInside); |
o = o->nextInPreOrder(); |
} |