Refactor HomeView to use new event callback naming guideline

See: https://github.com/codecombat/codecombat/wiki/Events,-subscriptions,-shortcuts#events
This commit is contained in:
Scott Erickson 2015-10-21 14:18:13 -07:00
parent 452e6467b4
commit 6636051765

View file

@ -6,7 +6,7 @@ module.exports = class HomeView extends RootView
template: template template: template
events: events:
'click #play-button': 'onClickBeginnerCampaign' 'click #play-button': 'onClickPlayButton'
constructor: -> constructor: ->
super() super()
@ -34,7 +34,7 @@ module.exports = class HomeView extends RootView
c.isIPadBrowser = @isIPadBrowser() c.isIPadBrowser = @isIPadBrowser()
c c
onClickBeginnerCampaign: (e) -> onClickPlayButton: (e) ->
@playSound 'menu-button-click' @playSound 'menu-button-click'
e.preventDefault() e.preventDefault()
e.stopImmediatePropagation() e.stopImmediatePropagation()