mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 15:40:19 +00:00
LibWeb: Use correct realm when focusing HTMLTextAreaElement
This matches HTMLInputElement, and fixes the crash when focusing a textarea.
This commit is contained in:
parent
b32b277192
commit
dcf3bdcb9a
Notes:
sideshowbarker
2024-07-17 09:39:38 +09:00
Author: https://github.com/AtkinsSJ Commit: https://github.com/SerenityOS/serenity/commit/dcf3bdcb9a Pull-request: https://github.com/SerenityOS/serenity/pull/21265
1 changed files with 1 additions and 1 deletions
|
@ -56,7 +56,7 @@ void HTMLTextAreaElement::did_receive_focus()
|
||||||
return;
|
return;
|
||||||
if (!m_text_node)
|
if (!m_text_node)
|
||||||
return;
|
return;
|
||||||
browsing_context->set_cursor_position(DOM::Position::create(*vm().current_realm(), *m_text_node, 0));
|
browsing_context->set_cursor_position(DOM::Position::create(realm(), *m_text_node, 0));
|
||||||
}
|
}
|
||||||
|
|
||||||
void HTMLTextAreaElement::did_lose_focus()
|
void HTMLTextAreaElement::did_lose_focus()
|
||||||
|
|
Loading…
Reference in a new issue