       @snap() if @parent.getOption "snap"
 
   getPosition:->
-    maxValue = @parent.getOption('maxValue')
-    minValue = @parent.getOption('minValue')
-    value    = @getData().value
+    {maxValue, minValue} = @parent.getOptions()
+    {value}              = @getData()
 
     return ((value-minValue)*100)/(maxValue-minValue)
 
   setValue:(value)->
-    leftLimit     = @getData().leftLimit
-    rightLimit    = @getData().rightLimit
+    {leftLimit, rightLimit} = @getData()
 
     if !(value<leftLimit) and !(value>rightLimit)
       @data.value = value

class KDSliderBarView extends KDCustomHTMLView
  constructor:(options = {}, data = {})->
    options.cssClass    = KD.utils.curryCssClass "sliderbar-container", options.cssClass
    options.minValue   ?= 0
    options.maxValue   ?= 100

    @labels             = []

  createHandles:->
    for name, {value} of @getData().handles
      @handles.push @addSubView handle = new KDSliderBarHandleView {name}, {value}

    sortRef = (a,b) ->
      return -1 if a.getData().value < b.getData().value
