mirror of
https://github.com/linux-man/LoveFrames.git
synced 2024-11-18 16:04:22 +00:00
Add treenode:RemoveNode
This commit is contained in:
parent
dd5ae7d519
commit
f4416ca519
@ -268,6 +268,22 @@ function newobject:AddNode(text)
|
||||
|
||||
end
|
||||
|
||||
--[[---------------------------------------------------------
|
||||
- func: RemoveNode(id)
|
||||
- desc: removes a node from the object
|
||||
--]]---------------------------------------------------------
|
||||
function newobject:RemoveNode(id)
|
||||
|
||||
id = id + 1
|
||||
for k, v in ipairs(self.internals) do
|
||||
if k == id then
|
||||
v:Remove()
|
||||
break
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
--[[---------------------------------------------------------
|
||||
- func: SetOpen(bool)
|
||||
- desc: sets whether or not the object is open
|
||||
|
Loading…
Reference in New Issue
Block a user