            (java.io File)
            (javafx.concurrent Worker$State)
            (javafx.event EventHandler)
-           (javafx.scene.input KeyCode)))
+           (javafx.scene.input KeyCode)
+           (javafx.beans.value ChangeListener)))
 
 (defonce latch (CountDownLatch. 1))
 (defonce zoom (atom 1.0))


(defonce input-height (atom nil))
(defonce input-width (atom nil))

(defn update-zoom! [zoomvalue]
  (swap! zoom (fn [o] zoomvalue))

    (.setAll children [internal-webview])
    (.setScene internal-stage internal-scene)
    (.setOnZoom internal-scene zoom-handler)
    (.addListener (.widthProperty internal-scene) (reify ChangeListener
                                                    (changed [_ val old new]
                                                      (window-width-change-handler new))))
    (.addListener (.heightProperty internal-scene) (reify ChangeListener
                                                     (changed [_ val old new]
                                                       (window-height-change-handler new))))
    (.setOnKeyReleased internal-scene (reify EventHandler
                                        (handle [_ v]
                                          (key-released-handler v))))
    (.show internal-stage)
    (swap! engine (fn [x] internal-engine))
    (swap! stage (fn [x] internal-stage))
