1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-04 12:00:25 +00:00

Fix scale and position of popups with force_native.

This commit is contained in:
Pāvels Nadtočajevs
2025-06-15 17:18:03 +03:00
parent 46c495ca21
commit 34a97f9c9b
6 changed files with 25 additions and 1 deletions

View File

@@ -541,6 +541,10 @@ void OptionButton::show_popup() {
Rect2 rect = get_screen_rect();
rect.position.y += rect.size.height;
if (get_viewport()->is_embedding_subwindows() && popup->get_force_native()) {
Transform2D xform = get_viewport()->get_popup_base_transform_native();
rect = xform.xform(rect);
}
rect.size.height = 0;
popup->popup(rect);
}