godot-dockable-container
godot-dockable-container copied to clipboard
Refactor layout node classes to be RefCounted instead of sub-resources
This PR refactors layout node classes (DockableLayoutNode, DockableLayoutPanel and DockableLayoutSplit) to inherit from RefCounted instead of Resource. This makes all layout data concentrated in a single resource, avoiding sub-resources. Also, it doesn't make much sense for node classes to be standalone resources, they must live in a layout to be useful.
For serialization to work, there is a new serialized_data property that serializes this tree to/from a Dictionary.
Note: this is a breaking change, previously serialized DockableLayout resources will be reset, since the new data is not compatible with previous one.