       updateValue = (model) ->
         ngModel.$setViewValue(model)
         tempHolder.removeClass('active')
-        $timeout ->
-          setInitialValue() unless isMobile
+        setInitialValue()
       done = false
       fieldset = element
       until done

            li = angular.element '<a class="item">' + viewValueFn(item) + '</a>'
          ip = angular.element '<input type="hidden">'
          ip.val(modelValueFn(item))
          li.append(ip)
          li.bind 'mousedown', ($event)->
            updateValue($event.target.children[0].value)
          template.append(li)
      setInitialValue = ->
        unless isMobile
          obj = {}
          obj[modelValue] = ngModel.$modelValue
          list = $filter('filter')(collection(scope), obj,true)
          viewScope = list[0] if list
          search.val(if viewScope then viewValueFn(viewScope) else '')
        else

        span.append tempHolder
        element.append span
        tempHolder.append template
      equiv = (left,right) ->
        return true if left == right
        return true if (!!left && !!right) == false
        if !isNaN(left) && !isNaN(right)
          return true if parseFloat(left) == parseFloat(right)
        false

      ulHeight = ->
        full = window.innerHeight
