mirror of https://github.com/status-im/reagent.git
Avoid warning with ClojureScript 2156
This commit is contained in:
parent
c783d09b04
commit
85e5f8d46a
|
@ -25,16 +25,16 @@
|
|||
|
||||
(defn drag-end-fn [drag-move drag-end]
|
||||
(fn [evt]
|
||||
(events/unlisten js/window EventType/MOUSEMOVE drag-move)
|
||||
(events/unlisten js/window EventType/MOUSEUP @drag-end)))
|
||||
(events/unlisten js/window EventType.MOUSEMOVE drag-move)
|
||||
(events/unlisten js/window EventType.MOUSEUP @drag-end)))
|
||||
|
||||
(defn dragging [on-drag]
|
||||
(let [drag-move (drag-move-fn on-drag)
|
||||
drag-end-atom (atom nil)
|
||||
drag-end (drag-end-fn drag-move drag-end-atom)]
|
||||
(reset! drag-end-atom drag-end)
|
||||
(events/listen js/window EventType/MOUSEMOVE drag-move)
|
||||
(events/listen js/window EventType/MOUSEUP drag-end)))
|
||||
(events/listen js/window EventType.MOUSEMOVE drag-move)
|
||||
(events/listen js/window EventType.MOUSEUP drag-end)))
|
||||
|
||||
(defn point [{:keys [on-drag]} p]
|
||||
[:circle
|
||||
|
|
Loading…
Reference in New Issue