Sha256: 94dedc27978ee1672a49bdc2cff159c861a452a9e8be64eac62df0864286f876

Contents?: true

Size: 401 Bytes

Versions: 11

Compression:

Stored size: 401 Bytes

Contents

ELA.Views ?= {}
class ELA.Views.Headup extends Backbone.Poised.View
  activate: (control) =>
    # Clone the control view to add a new DOM element showing the same values
    @subviews.control = control.clone()
    @$el.addClass('active')
    @render()

  deactivate: =>
    @$el.removeClass('active')
    @subviews.control.remove()

  render: =>
    @$el.html(@subviews.control.render().el)
    this

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
ela-3.4.3 app/js/lib/views/headup.coffee
ela-3.4.2 app/js/lib/views/headup.coffee
ela-3.4.0 app/js/lib/views/headup.coffee
ela-3.3.1 app/js/lib/views/headup.coffee
ela-3.3.0 app/js/lib/views/headup.coffee
ela-3.2.0 app/js/lib/views/headup.coffee
ela-3.1.1 app/js/lib/views/headup.coffee
ela-3.1.0 app/js/lib/views/headup.coffee
ela-3.0.0 app/js/lib/views/headup.coffee
ela-2.0.0 app/js/lib/views/headup.coffee
ela-1.1.0 app/js/lib/views/headup.coffee