diff --git a/.gitignore b/.gitignore index d9c846e..88fa3ca 100644 --- a/.gitignore +++ b/.gitignore @@ -3,6 +3,7 @@ /classes /checkouts pom.xml +pom.xml.asc *.jar *.class .lein-repl-history diff --git a/project.clj b/project.clj index 36fcc54..e6dd5ff 100644 --- a/project.clj +++ b/project.clj @@ -1,4 +1,4 @@ -(defproject rhizome "0.2.3" +(defproject rhizome "0.2.4-SNAPSHOT" :description "a simple way to visualize graphs" :license {:name "MIT License" :url "http://opensource.org/licenses/MIT"} diff --git a/src/rhizome/viz.clj b/src/rhizome/viz.clj index d7384fb..f3cdd9b 100644 --- a/src/rhizome/viz.clj +++ b/src/rhizome/viz.clj @@ -34,7 +34,7 @@ (defn create-frame "Creates a frame for viewing graphviz images. Only useful if you don't want to use the default frame." - [{:keys [name close-promise]}] + [{:keys [name close-promise dispose-on-close?]}] (delay (let [frame (JFrame. ^String name) image-icon (ImageIcon.) @@ -52,6 +52,8 @@ (proxy [WindowAdapter] [] (windowClosing [e] (.setVisible frame false) + (when dispose-on-close? + (.dispose frame)) (when close-promise (deliver close-promise true))))) (.setContentPane pane)