Fix highlight error when opening browser tools

This commit is contained in:
Matt Lott 2014-10-09 17:55:38 -07:00
parent 7487df5af8
commit 37ac9f1a69

View file

@ -430,7 +430,7 @@ module.exports = class PlayLevelView extends RootView
viewArgs: [{supermodel: @supermodel, autoUnveil: true}, @levelID]
}
onWindowResize: (e) -> @endHighlight()
onWindowResize: (e) -> @endHighlight?()
onDisableControls: (e) ->
return if e.controls and not ('level' in e.controls)
@ -500,7 +500,7 @@ module.exports = class PlayLevelView extends RootView
onHighlightDOM: (e) -> @highlightElement e.selector, delay: e.delay, sides: e.sides, offset: e.offset, rotation: e.rotation
onEndHighlight: -> @endHighlight()
onEndHighlight: -> @endHighlight?()
onFocusDom: (e) -> $(e.selector).focus()