blob: b7b3aa871cb930b53e1e881a8af19356dc78e2ec (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
class Dashing.Meter extends Dashing.Widget
@accessor 'value', Dashing.AnimatedValue
constructor: ->
super
@observe 'max', (max) ->
$(@node).find(".meter").trigger('configure', {'max': max})
@observe 'min', (min) ->
$(@node).find(".meter").trigger('configure', {'min': min})
ready: ->
meter = $(@node).find(".meter")
meter.attr("data-bgcolor", meter.css("background-color"))
meter.attr("data-fgcolor", meter.css("color"))
meter.knob()
|