mirror of
https://github.com/godotengine/godot.git
synced 2026-01-06 10:11:57 +03:00
Change set_drag_forwarding() to use callables.
* This solution is much cleaner than the one in 3.x thanks to the use of callables. * Works without issues in any language (no need to worry about camel or snake case). * Editor code uses a compatibility function (too much work to redo). Fixes #59899
This commit is contained in:
@@ -2065,7 +2065,7 @@ void EditorInspectorArray::_setup() {
|
||||
ae.panel = memnew(PanelContainer);
|
||||
ae.panel->set_focus_mode(FOCUS_ALL);
|
||||
ae.panel->set_mouse_filter(MOUSE_FILTER_PASS);
|
||||
ae.panel->set_drag_forwarding(this);
|
||||
ae.panel->set_drag_forwarding_compat(this);
|
||||
ae.panel->set_meta("index", begin_array_index + i);
|
||||
ae.panel->set_tooltip_text(vformat(TTR("Element %d: %s%d*"), i, array_element_prefix, i));
|
||||
ae.panel->connect("focus_entered", callable_mp((CanvasItem *)ae.panel, &PanelContainer::queue_redraw));
|
||||
|
||||
Reference in New Issue
Block a user