🎉 Add interactions with the mouse

This commit is contained in:
Andrés Moya 2020-05-11 15:19:38 +02:00
parent 23ba635aab
commit e602a8cc36
4 changed files with 150 additions and 85 deletions

View file

@ -210,6 +210,15 @@
(when-not (empty? rch)
(rx/of (commit-changes rch uch {:commit-local? true})))))))
(defn get-frame-at-point
[objects point]
(let [frames (cp/select-frames objects)]
(loop [frame (first frames)
rest (rest frames)]
(d/seek #(geom/has-point? % point) frames))))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Undo / Redo
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;