summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--editor/plugins/spatial_editor_plugin.h12
-rw-r--r--modules/gridmap/grid_map_editor_plugin.cpp6
2 files changed, 10 insertions, 8 deletions
diff --git a/editor/plugins/spatial_editor_plugin.h b/editor/plugins/spatial_editor_plugin.h
index f3a1e657cc..ebaa930eb0 100644
--- a/editor/plugins/spatial_editor_plugin.h
+++ b/editor/plugins/spatial_editor_plugin.h
@@ -178,6 +178,12 @@ public:
GIZMO_GRID_LAYER = 25
};
+ enum NavigationScheme {
+ NAVIGATION_GODOT,
+ NAVIGATION_MAYA,
+ NAVIGATION_MODO,
+ };
+
private:
int index;
String name;
@@ -260,12 +266,6 @@ private:
PopupMenu *selection_menu;
- enum NavigationScheme {
- NAVIGATION_GODOT,
- NAVIGATION_MAYA,
- NAVIGATION_MODO,
- };
-
enum NavigationZoomStyle {
NAVIGATION_ZOOM_VERTICAL,
NAVIGATION_ZOOM_HORIZONTAL
diff --git a/modules/gridmap/grid_map_editor_plugin.cpp b/modules/gridmap/grid_map_editor_plugin.cpp
index 890bd730f7..6b9a97efb4 100644
--- a/modules/gridmap/grid_map_editor_plugin.cpp
+++ b/modules/gridmap/grid_map_editor_plugin.cpp
@@ -664,8 +664,10 @@ bool GridMapEditor::forward_spatial_input_event(Camera *p_camera, const Ref<Inpu
}
if (mb->is_pressed()) {
-
- if (mb->get_button_index() == BUTTON_LEFT) {
+ SpatialEditorViewport::NavigationScheme nav_scheme = (SpatialEditorViewport::NavigationScheme)EditorSettings::get_singleton()->get("editors/3d/navigation/navigation_scheme").operator int();
+ if ((nav_scheme == SpatialEditorViewport::NAVIGATION_MAYA || nav_scheme == SpatialEditorViewport::NAVIGATION_MODO) && mb->get_alt()) {
+ input_action = INPUT_NONE;
+ } else if (mb->get_button_index() == BUTTON_LEFT) {
if (input_action == INPUT_PASTE) {
_do_paste();