Start core-ui

This commit is contained in:
oakes
2014-01-08 03:20:05 -05:00
parent e9658884e6
commit fa07f45c3d
5 changed files with 114 additions and 6 deletions

View File

@@ -2,13 +2,15 @@
(:require [clojure.string :as s])
(:import [com.badlogic.gdx.utils Array]))
(def ^:const gdx-package "com.badlogic.gdx.")
(defn- split-key
[key]
(-> key name (s/split #"-")))
(defn- join-keys
[keys]
(->> keys (map name) (s/join ".") (str "com.badlogic.gdx.")))
(->> keys (map name) (s/join ".") (str gdx-package)))
(defn gdx-static-field*
[args]
@@ -27,6 +29,13 @@
[a]
(Array. true (into-array a) 1 (count a)))
(defn key->class
[k]
(->> (split-key k)
(map s/capitalize)
(s/join "")
symbol))
(defn key->method
[k]
(let [parts (split-key k)]