Fixed the context-menu preventer in the level editor.

This commit is contained in:
Scott Erickson 2014-04-15 12:27:35 -07:00
parent bb53e963b6
commit b238ccaf27

View file

@ -179,6 +179,7 @@ module.exports = class ThangsTabView extends View
destroy: ->
@selectAddThangType null
@surface.destroy()
$(document).bind 'contextmenu', @preventDefaultContextMenu
super()
onViewSwitched: (e) ->
@ -426,6 +427,7 @@ module.exports = class ThangsTabView extends View
@$el.find('.thangs-column').show()
preventDefaultContextMenu: (e) ->
return unless $(e.target).closest('#canvas-wrapper').length
e.preventDefault()
onSpriteContextMenu: (e) ->