cursor set to arrow on tree nodes and items by default

This commit is contained in:
David Botton 2024-07-18 00:31:56 -04:00
parent 94141026e6
commit edf6d04080

View file

@ -38,6 +38,7 @@ on the tree-root or other clog-tree's."))
(on-context-menu nil) (on-context-menu nil)
(fill-function nil) (fill-function nil)
(visible t) (visible t)
(style "cursor:default;")
(class nil) (class nil)
(html-id nil) (html-id nil)
(auto-place t)) (auto-place t))
@ -45,6 +46,7 @@ on the tree-root or other clog-tree's."))
icon. When FILL-FUNCTION, when clog-tree is visible the FILL-FUNCTION is called icon. When FILL-FUNCTION, when clog-tree is visible the FILL-FUNCTION is called
and when not visible (such as clicked to close) the children are destroyed." and when not visible (such as clicked to close) the children are destroyed."
(let* ((new-obj (create-div obj :content (format nil "~A " node-html) (let* ((new-obj (create-div obj :content (format nil "~A " node-html)
:style style
:class class :class class
:html-id html-id :html-id html-id
:auto-place auto-place)) :auto-place auto-place))
@ -80,7 +82,7 @@ and when not visible (such as clicked to close) the children are destroyed."
:cancel-event t)) ; prevent event bubble up tree :cancel-event t)) ; prevent event bubble up tree
new-obj)) new-obj))
(defmethod toggle-tree (clog-tree) (defgeneric toggle-tree (clog-tree)
(:documentation "Toggle state of tree node")) (:documentation "Toggle state of tree node"))
(defmethod toggle-tree ((obj clog-tree)) (defmethod toggle-tree ((obj clog-tree))
@ -100,12 +102,14 @@ and when not visible (such as clicked to close) the children are destroyed."
(node-html "📄") ; file icon (node-html "📄") ; file icon
(on-click nil) (on-click nil)
(on-context-menu nil) (on-context-menu nil)
(style "cursor:default;")
(class nil) (class nil)
(html-id nil) (html-id nil)
(auto-place t)) (auto-place t))
"Creates a clog-tree-item node labeled CONTENT with INDENT-LEVEL using NODE-HTML "Creates a clog-tree-item node labeled CONTENT with INDENT-LEVEL using NODE-HTML
icon. If INDENT-LEVEL is nil get parent's INDENT-LEVEL from obj if is a clog-tree." icon. If INDENT-LEVEL is nil get parent's INDENT-LEVEL from obj if is a clog-tree."
(let* ((new-obj (create-div obj :content (format nil "~A " node-html) (let* ((new-obj (create-div obj :content (format nil "~A " node-html)
:style style
:class class :class class
:html-id html-id :html-id html-id
:auto-place auto-place)) :auto-place auto-place))