Created
July 27, 2011 10:22
-
-
Save jonase/1109097 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns uitest | |
(:require [goog.ui.ComboBox :as ComboBox] | |
[goog.ui.ComboBoxItem :as ComboBoxItem] | |
[goog.dom :as dom])) | |
(defn ^:export add-combo-box [] | |
(let [combo-box (goog.ui/ComboBox.) ;; <-- ? | |
items ["A" "B" "C"] | |
elem (dom/getElement "combobox")] | |
(doseq [item items] | |
(.addItem combo-box (goog.ui/ComboBoxItem. item))) ;; <-- ? | |
(doto combo-box | |
(.setUseDropdownArrow true) | |
(.render elem)))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment