     this
 
   close: ->
-    $(window).off 'keyup', @escape
-    $(window).off 'resize', @resize
+    @$window.off 'keyup', @escape
+    @$window.off 'resize', @resize
 
     mediator.off null, null, this
 

      in:   => @updatePosition()

  setWidth: (width) ->
    @$dialog.css { width: width || @width }

  setup: ->
    # Render outer


  updatePosition: =>
    @$dialog.css
      top:  ((@$window.height() - @$dialog.height()) / 2) + 'px'
      left: ((@$window.width() - @$dialog.width()) / 2) + 'px'

  # Fade out body,
  # re-render the (presumably changed) template,
