         mode))))
 
 
-(inherit-multimethod set-selection-handler ::tree-control
+(defn-typecheck-swing-threads* set-selection-handler ::tree-control
   "Sets the selection-handler for the tree-control which is
    called every time the selection changes to handler.
 

      (if (managed-by-conexp-gui-editors-util? obj) (:control obj) obj))))


(inherit-multimethod get-size ::widget
  "Returns the size of the given widget.

   Parameters:
     obj         _widget")

(defmethod-swing get-size ::widget
  [obj]
  (bean (.getSize (get-widget obj))))

(inherit-multimethod set-size ::widget
  "Sets the size of the given widget.

   Parameters:
     obj         _widget
     width       _width
     height      _height")

(defmethod-swing-threads* set-size ::widget
  [obj width height]
  (.setSize (get-widget obj) (Dimension. width height)))

(inherit-multimethod set-width ::widget
  "Sets the width of the given widget.

   Parameters:
     obj         _widget
     width       _width")

(defmethod set-width ::widget
  [obj width]
  (let [ height (:height (get-size obj)) ]
    (set-size obj width height)))

(inherit-multimethod set-height ::widget
  "Sets the height of the given widget.

   Parameters:
     obj         _widget
     height      _height")

(defmethod set-height ::widget
  [obj height]
  (let [ width (:width (get-size obj)) ]
    (set-size obj width height)))

    keystroke  _a corresponding keystroke object
    condition  _can be either :focus, :widget, or :ancestor
                (determines which widget has to be focused to trigger the
                 action)"
  [otable handler name keystroke condition]
  (let [ java-condition ({:focus JComponent/WHEN_FOCUSED
                          :widget JComponent/WHEN_IN_FOCUSED_WINDOW
