     @input.html(html)
 
   showSuccess: ->
+    console.log @msg
     @element.removeClass "invalid"
     @element.removeClass "maybevalid"
     @element.addClass "valid"


    @update = ->
      @initialize()
      console.log 'ok'

  initialize: ->
    # Return if readonly (display) mode.

    @resultMenu.hide()

  createResultMenu: ->
    if $(".token-text-area-menu")
      @resultMenu = @element.find(".token-text-area-menu")
    else
      @resultMenu = $("<div class='token-text-area-menu'><ul class='token-text-area-results'></ul></div")
      @element.append @resultMenu
    @resultList = @resultMenu.find "ul"

  selectNextResult: (offset) ->
