Godot Version
4.4.1
Question
Hi, I’m trying to customize my inspector using EditorInspectorPlugin. I have successfully added an EditorResourcePicker component, but when I click on it, the panel doesn’t expand and show its properties like the built-in EditorResourcePicker. How can I achieve this? Thanks!
func _parse_property(
object: Object,
type: Variant.Type,
name: String,
hint_type: PropertyHint,
hint_string: String,
usage_flags: int,
wide: bool) -> bool:
if name == "stream":
var resource_picker = EditorResourcePicker.new()
resource_picker.set_editable(true)
resource_picker.toggle_mode = true
resource_picker.set_base_type("AudioStream")
resource_picker.resource_changed.connect(_on_picker_resource_changed.bind(object, name))
add_custom_control(resource_picker)
#add_property_editor(name, resource_picker)