summaryrefslogtreecommitdiff
path: root/editor/editor_file_dialog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/editor_file_dialog.cpp')
-rw-r--r--editor/editor_file_dialog.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/editor/editor_file_dialog.cpp b/editor/editor_file_dialog.cpp
index ec8651ac7c..b5300bdc1b 100644
--- a/editor/editor_file_dialog.cpp
+++ b/editor/editor_file_dialog.cpp
@@ -608,7 +608,8 @@ void EditorFileDialog::_item_list_item_rmb_selected(int p_item, const Vector2 &p
}
if (item_menu->get_item_count() > 0) {
- item_menu->set_position(item_list->get_global_position() + p_pos);
+ item_menu->set_position(item_list->get_screen_position() + p_pos);
+ item_menu->reset_size();
item_menu->popup();
}
}
@@ -629,7 +630,8 @@ void EditorFileDialog::_item_list_rmb_clicked(const Vector2 &p_pos) {
item_menu->add_separator();
item_menu->add_icon_item(item_list->get_theme_icon(SNAME("Filesystem"), SNAME("EditorIcons")), TTR("Open in File Manager"), ITEM_MENU_SHOW_IN_EXPLORER);
- item_menu->set_position(item_list->get_global_position() + p_pos);
+ item_menu->set_position(item_list->get_screen_position() + p_pos);
+ item_menu->reset_size();
item_menu->popup();
}