     @notify @_getFooter()
 
   _onKey: (key) ->
+    if config.keyCallback and not config.keyCallback key
+      return
+
     # check if the pressed key is configured
     draw = switch key?.name
       when "q"
-        process.exit 0
-
-      when "w" then @zoomy = 1
-      when "s" then @zoomy = -1
+        if config.quitCallback
+          config.quitCallback()
+        else
+          process.exit 0
 
       when "a" then @zoomBy config.zoomStep
-      when "z" then @zoomBy -config.zoomStep
+      when "z", "y"
+        @zoomBy -config.zoomStep
 
       when "left" then @moveBy 0, -8/Math.pow(2, @zoom)
       when "right" then @moveBy 0, 8/Math.pow(2, @zoom)


    if draw isnt null
      @_draw()
    else
      # display debug info for unhandled keys
      @notify JSON.stringify key

  _draw: ->
    @renderer

      @notify @_getFooter()
    .catch =>
      @notify "renderer is busy"

  _getFooter: ->
    # tile = utils.ll2tile @center.lon, @center.lat, @zoom
