Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(585)

Issue 2212293002: Use LayoutObject::selectionState() to check whether selection contains node or not (Closed)

Created:
4 years, 4 months ago by yosin_UTC9
Modified:
4 years, 4 months ago
Reviewers:
yoichio, Xiaocheng
CC:
blink-reviews, chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Use LayoutObject::selectionState() to check whether selection contains node or not This patch changes |FrameSelection::respondToNodeModification()| to check whether node to be removed in selection or not by using value of |LayoutObject::selectionState()| instead of using |Range::intersectsNode()| to make node removal faster. Execution time of attached performance test on my local PC: Before: 3.80ms After: 2.92ms "fast/repaint/selection-after-remove.html" needs rebaseline since this patch reduce invalidate elements, e.g. HTML and BODY elements aren't invalidated. BUG=259874, 505335, 632333 TEST=PerformanceTests/DOM/remove_child_with_selection.html Committed: https://crrev.com/3316ab0c51851da3f4ad14a7a273c21b542ba8f4 Cr-Commit-Position: refs/heads/master@{#410308}

Patch Set 1 : 2016-08-05T15:40:43 #

Patch Set 2 : 2016-08-08T11:10:01 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+37 lines, -13 lines) Patch
M third_party/WebKit/LayoutTests/TestExpectations View 1 1 chunk +2 lines, -0 lines 0 comments Download
A third_party/WebKit/PerformanceTests/DOM/remove_child_with_selection.html View 1 chunk +25 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/editing/FrameSelection.cpp View 1 2 chunks +10 lines, -13 lines 0 comments Download

Messages

Total messages: 22 (17 generated)
yosin_UTC9
PTAL
4 years, 4 months ago (2016-08-08 04:30:20 UTC) #16
Xiaocheng
lgtm
4 years, 4 months ago (2016-08-08 05:07:31 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2212293002/20001
4 years, 4 months ago (2016-08-08 06:06:04 UTC) #19
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 4 months ago (2016-08-08 06:09:23 UTC) #20
commit-bot: I haz the power
4 years, 4 months ago (2016-08-08 06:11:22 UTC) #22
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/3316ab0c51851da3f4ad14a7a273c21b542ba8f4
Cr-Commit-Position: refs/heads/master@{#410308}

Powered by Google App Engine
This is Rietveld 408576698