Skip to content

Commit

Permalink
LibWeb: Improve <select> dropdown position
Browse files Browse the repository at this point in the history
  • Loading branch information
Psychpsyo authored and AtkinsSJ committed Jan 14, 2025
1 parent 3e81d7e commit 5b9d18b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Libraries/LibWeb/HTML/HTMLSelectElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ void HTMLSelectElement::show_the_picker_if_applicable()
// Request select dropdown
auto weak_element = make_weak_ptr<HTMLSelectElement>();
auto rect = get_bounding_client_rect();
auto position = document().navigable()->to_top_level_position(Web::CSSPixelPoint { rect->x(), rect->y() });
auto position = document().navigable()->to_top_level_position(Web::CSSPixelPoint { rect->x(), rect->y() + rect->height() });
document().page().did_request_select_dropdown(weak_element, position, CSSPixels(rect->width()), m_select_items);
set_is_open(true);
}
Expand Down

0 comments on commit 5b9d18b

Please sign in to comment.