|
|
Chromium Code Reviews
Description[Editing] Use VisiblePosition stardOfWord for textarea in spell checker.
TextControlElement::{start,end}{Word,Sentence}() without VisiblePosition was
introduced for Speedometor benchmark.(crrev.com/db6862d16)
Since, editing is now pipeline friendly and hoisting have not caused regression,
we need not have such optimization functions.
This CL clean up code path. I will clean up the functions later.
BUG=639528
Committed: https://crrev.com/eb2857b079bd13cd8a26030b91d92adae3ecf041
Cr-Commit-Position: refs/heads/master@{#435592}
Patch Set 1 #
Total comments: 2
Patch Set 2 : update #
Messages
Total messages: 30 (19 generated)
The CQ bit was checked by yoichio@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
Description was changed from
==========
[Editing] textform::Enclosging
BUG=639528
==========
to
==========
[Editing] Let enclosingTextControl(node) return null if node is inner shadow
root.
TEXTAREA consists of
<textarea>
#shadowRoot
<div id=innerEditor>blah blah blah</div>
</textarea>
The issue is that
enclosingTextControl(Position(innerEditor, beforeAnchor)) returns the TEXTAERA
but innerNodePosition assumes position is in the DIV element.
enclosingTextControl(position) != null should mean position is in the DIV
element.
This CL changes enclosingTextControl return nullptr for such position.
BUG=639528
==========
yoichio@chromium.org changed reviewers: + yosin@chromium.org
I think enclosingTextControl() for beforeAnchor/afterAnchor of innerEditor is
TEXTAREA.
The root cause of the issue is selection has such positions after
canonicalization.
Rather than changing enclosingTextControl(), I recommend that removing
TextControlElement::{start,end}{Word,Sentence}() etc, called for TEXTAREA/INPUT
optimization introduced for Spedoo benchmark. Since, editing is now pipeline
friendly, we should not have such optimization because
they increase maintenance const like this bug.
Examples:
- TextControlElement::startOfWord() is called in one place and after updateSaL
- TextControlElement::endOfWord() is called in one place and after updateSaL
So, we can get rid of {start,end}OfWord() w/o speed regression.
{start,end}OfSentence() are called in {start,end}OfWord() are called in
{start,end}OfWord(),
so we get rid of them too.
https://codereview.chromium.org/2533213003/diff/1/third_party/WebKit/LayoutTe...
File
third_party/WebKit/LayoutTests/editing/selection/extend/go-out-of-readonly-textarea.html
(right):
https://codereview.chromium.org/2533213003/diff/1/third_party/WebKit/LayoutTe...
third_party/WebKit/LayoutTests/editing/selection/extend/go-out-of-readonly-textarea.html:9:
test(function(){
Could you add assert_*? What behavior do you expect?
https://codereview.chromium.org/2533213003/diff/1/third_party/WebKit/LayoutTe...
third_party/WebKit/LayoutTests/editing/selection/extend/go-out-of-readonly-textarea.html:11:
window.getSelection().extend(div);
Since selection anchor position is inside TEXTAREA, Selection#extend() should be
in TEXTAREA too thanks by editing boundary adjustment.
The CQ bit was checked by yoichio@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
> Rather than changing enclosingTextControl(), I recommend that removing
> TextControlElement::{start,end}{Word,Sentence}() etc, called for
TEXTAREA/INPUT
> optimization introduced for Spedoo benchmark. Since, editing is now pipeline
> friendly, we should not have such optimization because
> they increase maintenance const like this bug.
I confirmed neither change hoisting before TextControlElement::star/endOfWord in
SpellChecker::respondToChangedSelection
(crrev.com/c3f340d2)
nor one insertings DisallowTransitionScope(crrev.com/764af575f5)
have not caused regression:
https://chromeperf.appspot.com/report?sid=a25e331d89919e3ad599cc2bb29cbcc37b8...
Also I confirmed this CL don't cause regression on the speedometor benchmark
locally.
Description was changed from
==========
[Editing] Let enclosingTextControl(node) return null if node is inner shadow
root.
TEXTAREA consists of
<textarea>
#shadowRoot
<div id=innerEditor>blah blah blah</div>
</textarea>
The issue is that
enclosingTextControl(Position(innerEditor, beforeAnchor)) returns the TEXTAERA
but innerNodePosition assumes position is in the DIV element.
enclosingTextControl(position) != null should mean position is in the DIV
element.
This CL changes enclosingTextControl return nullptr for such position.
BUG=639528
==========
to
==========
[Editing] Use VisiblePosition stardOfWord for textarea in spell checker.
TextControlElement::{start,end}{Word,Sentence}() without VisiblePosition was
introduced for Speedometor benchmark.(crrev.com/db6862d16)
Since, editing is now pipeline friendly and hoisting have not caused regression,
we need not have such optimization functions.
BUG=639528
==========
Description was changed from
==========
[Editing] Use VisiblePosition stardOfWord for textarea in spell checker.
TextControlElement::{start,end}{Word,Sentence}() without VisiblePosition was
introduced for Speedometor benchmark.(crrev.com/db6862d16)
Since, editing is now pipeline friendly and hoisting have not caused regression,
we need not have such optimization functions.
BUG=639528
==========
to
==========
[Editing] Use VisiblePosition stardOfWord for textarea in spell checker.
TextControlElement::{start,end}{Word,Sentence}() without VisiblePosition was
introduced for Speedometor benchmark.(crrev.com/db6862d16)
Since, editing is now pipeline friendly and hoisting have not caused regression,
we need not have such optimization functions.
This CL clean up code path. I will clean up the functions later.
BUG=639528
==========
The CQ bit was checked by yosin@chromium.org
lgtm
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presub...)
yoichio@chromium.org changed reviewers: + tkent@chromium.org
+tkent. Could you take a look for core/html/* ?
rs lgtm
The CQ bit was checked by yosin@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
CQ is committing da patch.
Bot data: {"patchset_id": 20001, "attempt_start_ts": 1480586273240920,
"parent_rev": "3b2077e4d7e90e3146b97fc30854d0adbcd5432b", "commit_rev":
"75d6d1c74be87fcfcdc5acc4221f850716e8c36f"}
Message was sent while issue was closed.
Description was changed from
==========
[Editing] Use VisiblePosition stardOfWord for textarea in spell checker.
TextControlElement::{start,end}{Word,Sentence}() without VisiblePosition was
introduced for Speedometor benchmark.(crrev.com/db6862d16)
Since, editing is now pipeline friendly and hoisting have not caused regression,
we need not have such optimization functions.
This CL clean up code path. I will clean up the functions later.
BUG=639528
==========
to
==========
[Editing] Use VisiblePosition stardOfWord for textarea in spell checker.
TextControlElement::{start,end}{Word,Sentence}() without VisiblePosition was
introduced for Speedometor benchmark.(crrev.com/db6862d16)
Since, editing is now pipeline friendly and hoisting have not caused regression,
we need not have such optimization functions.
This CL clean up code path. I will clean up the functions later.
BUG=639528
==========
Message was sent while issue was closed.
Committed patchset #2 (id:20001)
Message was sent while issue was closed.
Description was changed from
==========
[Editing] Use VisiblePosition stardOfWord for textarea in spell checker.
TextControlElement::{start,end}{Word,Sentence}() without VisiblePosition was
introduced for Speedometor benchmark.(crrev.com/db6862d16)
Since, editing is now pipeline friendly and hoisting have not caused regression,
we need not have such optimization functions.
This CL clean up code path. I will clean up the functions later.
BUG=639528
==========
to
==========
[Editing] Use VisiblePosition stardOfWord for textarea in spell checker.
TextControlElement::{start,end}{Word,Sentence}() without VisiblePosition was
introduced for Speedometor benchmark.(crrev.com/db6862d16)
Since, editing is now pipeline friendly and hoisting have not caused regression,
we need not have such optimization functions.
This CL clean up code path. I will clean up the functions later.
BUG=639528
Committed: https://crrev.com/eb2857b079bd13cd8a26030b91d92adae3ecf041
Cr-Commit-Position: refs/heads/master@{#435592}
==========
Message was sent while issue was closed.
Patchset 2 (id:??) landed as https://crrev.com/eb2857b079bd13cd8a26030b91d92adae3ecf041 Cr-Commit-Position: refs/heads/master@{#435592} |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
