   [element]
   (log (str "Creating a player within " element))
   (let [player (jq/append element player-control)
-        play-btn (.find player "a.play")
-        pause-btn (.find player "a.pause")
-        back-btn (.find player "a.back")
-        forward-btn (.find player "a.forward")
-        player-state-atom (atom (create-player-state))]
-    
-    (add-watch player-state-atom :log 
-               (fn [k a o n]
-                 (log (str "Player state set to " n))))
-    
-    (.click play-btn    (partial button-state-helper player-state-atom play))
-    (.click pause-btn   (partial button-state-helper player-state-atom pause))
-    (.click back-btn    (partial button-state-helper player-state-atom back))
-    (.click forward-btn (partial button-state-helper player-state-atom forward))
+        player-state-atom (atom (create-player-state))
+        button-types-and-fns {:play play :pause pause :back back :forward forward
+                              :first jump-to-first :last jump-to-last}]
+    (doseq [[btn-type btn-fn] button-types-and-fns]
+      (setup-button player player-state-atom btn-type btn-fn))
     (partial player-data-handler player-state-atom)))
 

  ([items data-handler]
   {:items items
    :data-handler data-handler
    :index -1
    :playing true}))

(defn ^:export createPlayerFn
  "Creates a player component within the given element and returns a function

(def player-control 
  (hiccups/html [:div.btn-toolbar 
         [:div.btn-group
          [:a.btn.first {:href "#"}[:i.icon-step-backward]]
          [:a.btn.back {:href "#"}[:i.icon-backward]]
          [:a.btn.play {:href "#"}[:i.icon-play]]
          [:a.btn.pause {:href "#"}[:i.icon-pause]]
          [:a.btn.forward {:href "#"}[:i.icon-forward]]
          [:a.btn.last {:href "#"}[:i.icon-step-forward]]]]))

(defn- button-state-helper 
  "A helper function that will unwrap the state of the player state atom and invoke the 
