♻️ Rename helper root-frame? to is-direct-child-of-root?

This commit is contained in:
Pablo Alba 2023-07-24 15:50:35 +02:00 committed by Andrey Antukh
parent 35f931c05a
commit 577c2b39dc
11 changed files with 21 additions and 21 deletions

View file

@ -30,7 +30,7 @@
(not (ctl/layout-absolute? shape))
(or (cph/group-shape? shape)
(cph/frame-shape? shape)))
(cph/root-frame? shape))
(cph/is-direct-child-of-root? shape))
:relative
(and (ctl/any-layout-immediate-child? objects shape)
@ -54,14 +54,14 @@
;;shape (gsh/transform-shape)
shape-value (get selrect coord)
]
(when (and (not (cph/root-frame? shape))
(when (and (not (cph/is-direct-child-of-root? shape))
(or (not (ctl/any-layout-immediate-child? objects shape))
(ctl/layout-absolute? shape)))
(- shape-value parent-value))))
#_(defn get-shape-position
[shape objects coord]
(when-not (or (cph/root-frame? shape)
(when-not (or (cph/is-direct-child-of-root? shape)
(and (ctl/any-layout-immediate-child? objects shape)
(not (ctl/layout-absolute? shape))))
(let [parent (get objects (:parent-id shape))