LibWeb+WebContent+UI: Port text pasting to UTF-16

This commit is contained in:
Timothy Flynn 2025-09-18 09:18:54 -04:00 committed by Tim Flynn
parent ca082d6d73
commit efa9311527
Notes: github-actions[bot] 2025-09-19 10:39:52 +00:00
15 changed files with 19 additions and 20 deletions

View file

@ -156,7 +156,7 @@ void Internals::send_key(HTML::HTMLElement& target, String const& key_name, WebI
page().handle_keydown(key_code, modifiers, 0, false);
}
void Internals::paste(HTML::HTMLElement& target, String const& text)
void Internals::paste(HTML::HTMLElement& target, Utf16String const& text)
{
auto& page = this->page();
target.focus();

View file

@ -32,7 +32,7 @@ public:
void send_text(HTML::HTMLElement&, String const&, WebIDL::UnsignedShort modifiers);
void send_key(HTML::HTMLElement&, String const&, WebIDL::UnsignedShort modifiers);
void paste(HTML::HTMLElement& target, String const& text);
void paste(HTML::HTMLElement& target, Utf16String const& text);
void commit_text();
void click(double x, double y);

View file

@ -24,7 +24,7 @@ interface Internals {
undefined sendText(HTMLElement target, DOMString text, optional unsigned short modifiers = 0);
undefined sendKey(HTMLElement target, DOMString keyName, optional unsigned short modifiers = 0);
undefined paste(HTMLElement target, DOMString text);
undefined paste(HTMLElement target, Utf16DOMString text);
undefined commitText();
undefined click(double x, double y);