Skip to content

Commit cdf270a

Browse files
trflynn89gmta
authored andcommitted
WebContent: Invert focus condition in WebDriver's Element Send Keys
The spec states we should inspect the relevant value if the element does *not* have focus.
1 parent c566cc5 commit cdf270a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Services/WebContent/WebDriverConnection.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1979,7 +1979,7 @@ Web::WebDriver::Response WebDriverConnection::element_send_keys_impl(StringView
19791979
// 1. If element does not currently have focus, let current text length be the length of element's API value.
19801980
Optional<Web::WebIDL::UnsignedLong> current_text_length;
19811981

1982-
if (element->is_focused()) {
1982+
if (!element->is_focused()) {
19831983
auto api_value = target->relevant_value();
19841984

19851985
// FIXME: This should be a UTF-16 code unit length, but `set_the_selection_range` is also currently

0 commit comments

Comments
 (0)