 HIDE = 0
 OUTPUT = 1
 QUERY = 2
-IM = 3
 
 class PanelView extends View
 
     mode: HIDE
+    IM: false
 
     @content: ->
         @div outlet: 'agdaPanel', class: 'agda-panel tool-panel panel-bottom', =>

    #   Modes
    #

    query: ->
        if @mode isnt QUERY
            @mode = QUERY

            log 'Panel', "query mode"
            @show()
            @content.hide()
            @inputBox.show()

            @inputBox.focus()
            @promise = Q.Promise (resolve, reject, notify) =>
                # confirm

        return @

    output: ->
        @switchMode OUTPUT
        return @

    activateIM: ->
        if not @IM
            @IM = true
            log 'Panel', "IM on"
            @title.hide()
            @inputMethod.show()
        return @

    deactivateIM: ->
        if @IM
            @IM = false
            log 'Panel', "IM off"
            @title.show()
            @inputMethod.hide()
        return @
