gecko-dev/testing/web-platform
Masayuki Nakano 4bb761eb3e Bug 1863759 - Make `IMEStateManager` recreate `IMEContentObserver` if the active one is not observing editable content of focused element r=smaug,m_kato
The test case is a special case that changes focused element from a text control
to an editing host.  Therefore, without a focus change, focused editor is
changed from a `TextEditor` to `HTMLEditor`.  At this time, `IMEContentObserver`
needs to switch the observing target from the anonymous content if `<input>` to
children of it.

However, the editable content becomes completely changed without a focus change
in the DOM.  Therefore, `IMEStateManager` needs to synthesize a fake focus move
for IME.  Therefore, this patch make `IMEStateManager` recreate
`IMEContentObserver` if active one is not observing editable content for the
focused element under "current" conditions at checking it.  (When
`IMEContentObserver` is being destroyed, it sends "blur" notification to IME
and the new `IMEContentObserver` instance posts "focus" notification with
all editable content data.  I.e., recreating `IMEContentObserver` generates
a fake focus move from IME point of view.)

Additionally, there is the opposite case, that is, editing host of an `<input>`
whose type is not a text control may become a text control.  Therefore, this
adds new WPTs to check the handler is the text editor for the text control or
the HTML editor.  The tests passed on Firefox and Chrome at least.

FYI: I guess that in this case, we need to kick `focus` event listener of the
`HTMLEditor`, but anyway, users cannot change the content because it's the
case that an atomic content is the editing host.  Therefore, I don't touch
about that in this patch.

Differential Revision: https://phabricator.services.mozilla.com/D193262
2023-12-05 02:33:18 +00:00
..
docs
meta Backed out changeset 3d0a5f6fd8b4 (bug 1609403) for causing failures on grid-self-baseline-changes-grid-area-size-002.html. CLOSED TREE 2023-12-05 01:37:51 +02:00
mozilla Bug 1862391 - [wdspec] Add more tests for "origin" argument of "browsingContext.captureScreenshot" command. r=webdriver-reviewers,whimboo 2023-12-01 14:50:24 +00:00
outbound
products
tests Bug 1863759 - Make `IMEStateManager` recreate `IMEContentObserver` if the active one is not observing editable content of focused element r=smaug,m_kato 2023-12-05 02:33:18 +00:00
update
fissionregressions.py Bug 1865645 - drop Windows service pack support from mozinfo.py. r=jmaher,jgraham 2023-11-20 15:26:20 +00:00
interop.py
mach_commands.py Bug 1834782 - Add WPT root directory into system path for wpt-serve r=jgraham 2023-11-22 15:49:36 +00:00
mach_commands_base.py
mach_test_package_commands.py
manifestdownload.py
manifestupdate.py
metamerge.py
metasummary.py
moz.build
python.ini
runtests.py
test_metamerge.py
unittestrunner.py
vcs.py
wptrunner.ini