Skip to content

Commit

Permalink
Dev: Don't drag-n-drop non-buttons in quick-menu
Browse files Browse the repository at this point in the history
  • Loading branch information
olleharstedt committed May 5, 2016
1 parent c311a44 commit adb922b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion styles/Sea_Green/scripts/sidemenu.js
Expand Up @@ -466,8 +466,14 @@ function drop_handler(ev) {
// TODO: Why is ev.target not <a>, but <div>?
var $target = $(ev.target).parent().parent();
var data = ev.dataTransfer.getData("text");
$target.after(data);
$(ev.target).css('background-color', 'white');

if (data.indexOf("quick-menu-item") < 0)
{
return;
}

$target.after(data);
drop_delete_fn();

// Delete left-over tooltip
Expand Down

0 comments on commit adb922b

Please sign in to comment.