Explorar o código

Merge pull request #6094 from djrm/texure_region_zoom_by_scroll

Zoom texture region using mouse wheel
Rémi Verschelde %!s(int64=9) %!d(string=hai) anos
pai
achega
475b944f9c
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      tools/editor/plugins/texture_region_editor_plugin.cpp

+ 4 - 0
tools/editor/plugins/texture_region_editor_plugin.cpp

@@ -388,6 +388,10 @@ void TextureRegionEditor::_region_input(const InputEvent& p_input)
 					drag_index = -1;
 					drag_index = -1;
 				}
 				}
 			}
 			}
+		} else if (mb.button_index == BUTTON_WHEEL_UP) {
+			_zoom_in();
+		} else if (mb.button_index == BUTTON_WHEEL_DOWN) {
+			_zoom_out();
 		}
 		}
 	} else if (p_input.type==InputEvent::MOUSE_MOTION) {
 	} else if (p_input.type==InputEvent::MOUSE_MOTION) {