Open Bug 1341977 Opened 7 years ago Updated 2 years ago

Cannot move caret after trying to do "Kakutei-Undo" of Apple Japanese Input in twitter.com

Categories

(Core :: DOM: UI Events & Focus Handling, defect, P3)

All
macOS
defect

Tracking

()

Tracking Status
firefox54 --- affected

People

(Reporter: masayuki, Assigned: m_kato)

References

()

Details

(Keywords: inputmethod, Whiteboard: tpi:+)

Attachments

(1 file)

STR:
1. Open https://twitter.com/ and log into it.
2. Set focus to the editor to tweet.
3. Input "テスト" and commit it.
4. Input "テスト" again and commit it.
5. Press Ctrl+Backspace

Expected result:
2nd "テスト" becomes marked text and it's impossible to convert it to other string.

Actual result:
Nothing happened and cannot move focus with arrow keys anymore.


I think that the editor to tweet hacks something. Therefore, it may be okay not to be able to do "Kakutei-Undo" but we should avoid the latter issue.

I reproduce this bug either in e10s mode nor non-e10s mode.
Priority: -- → P2
Whiteboard: tpi:+
Moving to p3 because no activity for at least 1 year(s).
See https://github.com/mozilla/bug-handling/blob/master/policy/triage-bugzilla.md#how-do-you-triage for more information
Priority: P2 → P3

Since this is interesting, so I investigate this today.

Twitter's UI removes all text by [ctrl] + [delete] on macOS. Since if their contents/scripts handle "Backspace" key to remove all content, their scripts remove all by it.

When using Apple Japanese IME with [ctrl] + [delete], before Firefox sets composition (it means to fire compositionstart and compositionupdate) for reconverting composition, twitter removes all text unfortunately. So this issue will occur. (also, Chrome is same)

But Safari's behavior is different. When using [ctrl] + [delete], they set IME Process key to keyCode instead of backspace key. So this issue doesn't occur on Safari.

This process key is correct when IME is handled. But I guess that Firefox and Chrome are also correct since both doesn't handle IME yet... Hmm....

Assignee: nobody → m_kato

[Ctrl] + [Backspace] is assigned as deleting all tweet in Twitter. [Ctrl] + [Backspace] is assigned as commit-undo in Apple Japanese input method. When using it, Gecko fires key down event of [Ctrl] + [Backspace], not process key, commit-undo in Apple IM doesn't work well. In this situation, WebKit fires process key correctly, so it works expectedly.

Actually, since WebKit uses undocumented API (async version of NSTextInputClient, supported from 10.10) for key event by https://webkit.org/b/130479, this doesn't occur.

Since this change might be risky, I would like to turn on this for Nightly and early beta only. If no problem, I will turn on this for 71 release.

See Also: → 1583131

Moving all open keyboard/IME handling bugs to DOM: UI Events & Focus Handling component.

Component: Widget: Cocoa → DOM: UI Events & Focus Handling
See Also: → 1596399
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: