Merge pull request #49376 from menip/OptionButtonFix

This commit is contained in:
Rémi Verschelde
2021-09-17 16:00:42 +02:00
committed by GitHub
3 changed files with 8 additions and 6 deletions

View File

@@ -115,7 +115,7 @@ void OptionButton::_selected(int p_which) {
}
void OptionButton::pressed() {
Size2 size = get_size();
Size2 size = get_size() * get_viewport()->get_canvas_transform().get_scale();
popup->set_position(get_screen_position() + Size2(0, size.height * get_global_transform().get_scale().y));
popup->set_size(Size2(size.width, 0));
popup->popup();