Commit 014b5535 authored by Henning Leutz's avatar Henning Leutz 🥋

fix: #1004

parent 8b3b8956
......@@ -348,6 +348,18 @@ define('classes/projects/project/media/panel/ContextMenu', [
return;
}
var id, ids;
// check if its the same id
if (typeOf(Element) === 'element') {
ids = Element.get('data-ids').split(',');
id = Droppable.get('data-id');
if (ids.length === 1 && ids[0] === id) {
return;
}
}
var self = this,
Menu = this.getPanel().getContextMenu(),
title = Droppable.get('title'),
......@@ -449,8 +461,8 @@ define('classes/projects/project/media/panel/ContextMenu', [
}
var ids = Element.get('data-ids').split(','),
id = Droppable.get('data-id');
ids = Element.get('data-ids').split(',');
id = Droppable.get('data-id');
// show choices
Menu.appendChild(
......
......@@ -1171,7 +1171,7 @@ define('controls/projects/project/media/Panel', [
if (!files.length) {
return;
}
console.log('$viewOnDrop');
if (Elm.hasClass('qui-media-content')) {
this.$PanelContextMenu.showDragDropMenu(files, Elm, event);
return;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment