mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-16 07:20:46 +00:00
LibWeb: Subclass FormAssociatedElement text selection methods
These are only relevant to HTMLInputElement and HTMLTextArea elements.
This commit is contained in:
parent
7b2042571b
commit
206262cd55
Notes:
github-actions[bot]
2024-08-31 09:50:53 +00:00
Author: https://github.com/tcl3
Commit: 206262cd55
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1223
Reviewed-by: https://github.com/awesomekling
5 changed files with 47 additions and 47 deletions
|
@ -1159,7 +1159,7 @@ void EventHandler::update_selection_range_for_input_or_textarea()
|
|||
// FIXME: support selection directions other than ::Forward
|
||||
auto direction = HTML::SelectionDirection::Forward;
|
||||
|
||||
Optional<HTML::FormAssociatedElement&> target {};
|
||||
Optional<HTML::FormAssociatedTextControlElement&> target {};
|
||||
if (is<HTML::HTMLInputElement>(shadow_host))
|
||||
target = static_cast<HTML::HTMLInputElement&>(shadow_host);
|
||||
else if (is<HTML::HTMLTextAreaElement>(shadow_host))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue