      :get-center [dbb]
      #(.setView mymap (vector (first %) (last %)) 5))))
 
-(defn addmarkers-toolserver [map-bounds-string]
+(defn- addmarkers-toolserver [map-bounds-string]
   (let [ch (chan)
         markers (L/MarkerClusterGroup.)]
     (set! layers (conj layers markers))

    (.setView mymap (vector latitude longitude) 15)
    (addmarkers-toolserver (.toBBoxString (.getBounds mymap)))))

(defn maybe-show-here []
  (let [z (.getZoom mymap)
        sh (dom/by-id "showhere")]
    (when (>= z zoomlimit)
      (set! (.-innerHTML sh) "->?<-"))
    (when (< z zoomlimit)
      (set! (.-innerHTML sh) "...."))))

(.on mymap "zoomend" maybe-show-here)


(def zoomlimit 10)
(def layers '())

(defn- removelastlayer []
  (when (seq (last layers))
    (do (.removeLayer mymap (last layers))
        (set! (.-value (dom/by-id "per")) "")
