|
@@ -2033,16 +2033,19 @@ bool CanvasItemEditor::_gui_input_select(const Ref<InputEvent> &p_event) {
|
|
|
|
|
|
// Find the item to select
|
|
// Find the item to select
|
|
CanvasItem *canvas_item = NULL;
|
|
CanvasItem *canvas_item = NULL;
|
|
- Vector<_SelectResult> selection;
|
|
|
|
-
|
|
|
|
- // Retrieve the items
|
|
|
|
- _get_canvas_items_at_pos(click, selection);
|
|
|
|
|
|
|
|
// Retrieve the bones
|
|
// Retrieve the bones
|
|
|
|
+ Vector<_SelectResult> selection = Vector<_SelectResult>();
|
|
_get_bones_at_pos(click, selection);
|
|
_get_bones_at_pos(click, selection);
|
|
-
|
|
|
|
if (!selection.empty()) {
|
|
if (!selection.empty()) {
|
|
canvas_item = selection[0].item;
|
|
canvas_item = selection[0].item;
|
|
|
|
+ } else {
|
|
|
|
+ // Retrieve the canvas items
|
|
|
|
+ selection = Vector<_SelectResult>();
|
|
|
|
+ _get_canvas_items_at_pos(click, selection);
|
|
|
|
+ if (!selection.empty()) {
|
|
|
|
+ canvas_item = selection[0].item;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
if (!canvas_item) {
|
|
if (!canvas_item) {
|