I have an icon inside a list, id like to just be able to detect the double click on the icon - so i can delete the list, how is this possible (JQuerry Sortable)
$("#roleList").dblclick(function(e) {
var text = $(e.target).html();
$(e.target).fadeOut('slow', function() {
$("#deleteList").append(e.target);
});
});
<ul id="roleList" class='droptrue'>
<li class="ui-state-default" id="20~Role 1"><span class="ui-icon ui-icon-arrowthick-2-n-s"></span><input id="20" name="20" type="text" value="Director General" /></li>
<li class="ui-state-default" id="1~Role 2"><span class="ui-icon ui-icon-arrowthick-2-n-s"></span><input id="1" name="1" type="text" value="Director" /></li>
so i want to detect the click on the "ui-icon ui-icon-arrowthick-2-n-s" class so i can trigger a fadeout and "delete" that list item.
I'm guessing if i can do that, this wont work:
var text = $(e.target).html();
$(e.target).fadeOut('slow', function() {
$("#deleteList").append(e.target);
});
ill have to do a e.target.parent? cuz id like to fadeout the ENTIRE li and not just the icon..
Any help would be appreicated