You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the example i provided there are three gui's that i have made with slightly different scripts and or nodes. The basic idea is that you can drag an image from the left to the gui on the right and then it will replace the icon in the center.
The top one is the one i would expect to be working, but it does not. In this situation the can_drop is attached to the container of the gui. It would therefore expect it to be droppable on the entire surface, but it is not droppable on the texturebuttons inside the container.
The middle example is my current compromise. In this situation the can_drop is attached to the central textureButton. So it is atleast possible to drag and drop on a texturebutton.
The third example has again the can_drop attached to the container, but now the central icon has been replaced with a texturerect, This case it is possible to drop on the rect and the surrounding areas, but still not on the little buttons.
This seems to me inconsistent and for me its also a big inconvenience as i would like to keep all of the nodes as TextureButtons.
The text was updated successfully, but these errors were encountered:
Hi @wytzen, you have to change the mouse_filter property of your TextureButton and CenterContainer from 'Stop' to 'Pass' in the inspector. The HBoxContainer and TextureRect have 'Pass' set by default so that they don't make problems. The reasoning is that InpuEventMouse events (Button+Motion) don't propagate to the parent container if a child stops its propagation.
Setting the mouse_filter to 'Pass' should solve your issue. Considering the mouse_filter property, I'd say this is expected behaviour.
Godot version:
3.2.1
OS/device including version:
Win 10
Issue description:
Drag and drop events are not passed from a TextureBbutton to a parent container
Minimal reproduction project:
DragDropExample.zip
In the example i provided there are three gui's that i have made with slightly different scripts and or nodes. The basic idea is that you can drag an image from the left to the gui on the right and then it will replace the icon in the center.
The top one is the one i would expect to be working, but it does not. In this situation the can_drop is attached to the container of the gui. It would therefore expect it to be droppable on the entire surface, but it is not droppable on the texturebuttons inside the container.
The middle example is my current compromise. In this situation the can_drop is attached to the central textureButton. So it is atleast possible to drag and drop on a texturebutton.
The third example has again the can_drop attached to the container, but now the central icon has been replaced with a texturerect, This case it is possible to drop on the rect and the surrounding areas, but still not on the little buttons.
This seems to me inconsistent and for me its also a big inconvenience as i would like to keep all of the nodes as TextureButtons.
The text was updated successfully, but these errors were encountered: