   (bind-window-keys window ["SUBTRACT" "OPEN_BRACKET"]
                    (fn [] (swap! zoom-atom update-in [:zoom] #(max MIN-ZOOM (dec %))))))
 
+(defn watch-keys [window key-atom]
+  (let [key-adapter (proxy [KeyAdapter] []
+                      (keyPressed [e]
+                                  (swap! key-atom update-in [:keys] conj
+                                         (KeyEvent/getKeyText (.getKeyCode e))))
+                      (keyReleased [e]
+                                   (swap! key-atom update-in [:keys] disj
+                                          (KeyEvent/getKeyText (.getKeyCode e)))))]
+    (doseq [component (descendants window)]
+      (.addKeyListener component key-adapter))))
+
 ;; MAIN WINDOW AND PANEL
 
 (defn main-panel [screen-state available-tiles]

    (.setBounds 10 10 500 500)))

(defn show [available-tiles]
  (let [screen-state (atom (sorted-map :x 0 :y 0 :z 0 :zoom 0))
        panel (main-panel screen-state available-tiles)
        frame (main-frame)]
    (def at available-tiles)

    (handle-wheel panel screen-state)
    (handle-resize panel screen-state)
    (handle-zoom frame screen-state)
    (watch-keys frame screen-state)
    (display-follow panel screen-state)
    (display-follow panel available-tiles)
    frame))
