fix #1745 prevent firefox click after drag
parent
19a6043350
commit
e1d2388baa
|
@ -104,7 +104,11 @@ BacklogSortableDirective = ($repo, $rs, $rootscope, $tgConfirm) ->
|
||||||
item = $(item)
|
item = $(item)
|
||||||
itemUs = item.scope().us
|
itemUs = item.scope().us
|
||||||
|
|
||||||
item.find('a').removeClass('noclick')
|
# HACK: setTimeout prevents that firefox click
|
||||||
|
# event fires just after drag ends
|
||||||
|
setTimeout ( =>
|
||||||
|
item.find('a').removeClass('noclick')
|
||||||
|
), 300
|
||||||
|
|
||||||
return itemUs
|
return itemUs
|
||||||
|
|
||||||
|
@ -137,6 +141,7 @@ BacklogEmptySortableDirective = ($repo, $rs, $rootscope) ->
|
||||||
|
|
||||||
deleteElement(ui.item)
|
deleteElement(ui.item)
|
||||||
$scope.$emit("sprint:us:move", [itemUs], itemIndex, null)
|
$scope.$emit("sprint:us:move", [itemUs], itemIndex, null)
|
||||||
|
|
||||||
ui.item.find('a').removeClass('noclick')
|
ui.item.find('a').removeClass('noclick')
|
||||||
|
|
||||||
$scope.$on "$destroy", ->
|
$scope.$on "$destroy", ->
|
||||||
|
@ -168,7 +173,6 @@ SprintSortableDirective = ($repo, $rs, $rootscope) ->
|
||||||
itemUs = item.scope().us
|
itemUs = item.scope().us
|
||||||
|
|
||||||
deleteElement(item)
|
deleteElement(item)
|
||||||
item.find('a').removeClass('noclick')
|
|
||||||
|
|
||||||
return itemUs
|
return itemUs
|
||||||
|
|
||||||
|
@ -181,9 +185,18 @@ SprintSortableDirective = ($repo, $rs, $rootscope) ->
|
||||||
|
|
||||||
itemUs = ui.item.scope().us
|
itemUs = ui.item.scope().us
|
||||||
itemIndex = ui.item.index()
|
itemIndex = ui.item.index()
|
||||||
ui.item.find('a').removeClass('noclick')
|
|
||||||
|
# HACK: setTimeout prevents that firefox click
|
||||||
|
# event fires just after drag ends
|
||||||
|
setTimeout ( =>
|
||||||
|
ui.item.find('a').removeClass('noclick')
|
||||||
|
), 300
|
||||||
|
|
||||||
$scope.$emit("sprint:us:move", [itemUs], itemIndex, $scope.sprint.id)
|
$scope.$emit("sprint:us:move", [itemUs], itemIndex, $scope.sprint.id)
|
||||||
|
|
||||||
|
$el.on "sortstart", (event, ui) ->
|
||||||
|
ui.item.find('a').addClass('noclick')
|
||||||
|
|
||||||
return {link:link}
|
return {link:link}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue