Commit d339f64
[EditContext] Add UseCounter for updateText and updateSelection
This CL adds use counters to analyze the impact of implementing the
change proposed in [1]. Following counters are added:
1. kEditContextUpdateTextRangePrecedesOrOverlapsSelection: Tracks when
updateText is called and the update range precedes or overlaps the
selection.
2. kEditContextUpdateTextRangePrecedesCompositionRange: Tracks when
updateText is called and the update range precedes the composition
range during an active composition.
3. kEditContextUpdateTextRangeOverlapsCompositionRange: Tracks when
updateText is called and the update range overlaps with the composition
range during an active composition.
4. kEditContextUpdateSelectionDuringActiveComposition: Tracks when
updateSelection is called during an active composition.
[1] w3c/edit-context#115
These counters will help us understand how frequently these behaviors
occur before making changes to the spec implementation.
Bug: 379170477
Change-Id: I8043fdb6161137f79d8eaa3336b90d93ca25042c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6549358
Reviewed-by: Dan Clark <daniec@microsoft.com>
Commit-Queue: Ashish Kumar <ashishkum@microsoft.com>
Cr-Commit-Position: refs/heads/main@{#1462602}1 parent 12c2d46 commit d339f64
File tree
4 files changed
+119
-1
lines changed- third_party/blink
- public/mojom/use_counter/metrics
- renderer/core/editing/ime
- web_tests/editing/input
- tools/metrics/histograms/metadata/blink
4 files changed
+119
-1
lines changedLines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4888 | 4888 | | |
4889 | 4889 | | |
4890 | 4890 | | |
| 4891 | + | |
| 4892 | + | |
| 4893 | + | |
| 4894 | + | |
4891 | 4895 | | |
4892 | 4896 | | |
4893 | 4897 | | |
| |||
Lines changed: 33 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
243 | 243 | | |
244 | 244 | | |
245 | 245 | | |
246 | | - | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
247 | 256 | | |
248 | 257 | | |
249 | 258 | | |
| |||
309 | 318 | | |
310 | 319 | | |
311 | 320 | | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
312 | 344 | | |
313 | 345 | | |
314 | 346 | | |
| |||
Lines changed: 77 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
759 | 759 | | |
760 | 760 | | |
761 | 761 | | |
| 762 | + | |
| 763 | + | |
| 764 | + | |
| 765 | + | |
| 766 | + | |
| 767 | + | |
| 768 | + | |
| 769 | + | |
| 770 | + | |
| 771 | + | |
| 772 | + | |
| 773 | + | |
| 774 | + | |
| 775 | + | |
| 776 | + | |
| 777 | + | |
| 778 | + | |
| 779 | + | |
| 780 | + | |
| 781 | + | |
| 782 | + | |
| 783 | + | |
| 784 | + | |
| 785 | + | |
| 786 | + | |
| 787 | + | |
| 788 | + | |
| 789 | + | |
| 790 | + | |
| 791 | + | |
| 792 | + | |
| 793 | + | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
| 797 | + | |
| 798 | + | |
| 799 | + | |
| 800 | + | |
| 801 | + | |
| 802 | + | |
| 803 | + | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
| 838 | + | |
762 | 839 | | |
763 | 840 | | |
764 | 841 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6209 | 6209 | | |
6210 | 6210 | | |
6211 | 6211 | | |
| 6212 | + | |
| 6213 | + | |
| 6214 | + | |
| 6215 | + | |
| 6216 | + | |
6212 | 6217 | | |
6213 | 6218 | | |
6214 | 6219 | | |
| |||
0 commit comments