 
     $(window).bind @keyEventsToBeListened.join(' '), @bound "key"
 
-    $(window).bind "resize", (event)=>
-      @setWindowProperties event
-      @notifyWindowResizeListeners event
+    window.addEventListener "resize", @bound 'notifyWindowResizeListeners'
 
     document.addEventListener 'scroll', do =>
       timer  = null

    @focusListeners        = []

    @bindEvents()
    @setWindowProperties()

    super options, data


  unregisterWindowResizeListener:(instance)->
    delete @windowResizeListeners[instance.id]

  notifyWindowResizeListeners: (event)->
    event or= type : "resize"
    for own key, inst of @windowResizeListeners when inst._windowDidResize
      inst._windowDidResize event

do ->
  KD = require './kd.coffee'
  KD.registerSingleton "windowController", new KDWindowController