EditorResourcePicker

package
v0.0.0-...-7325ca5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 31, 2025 License: MIT Imports: 25 Imported by: 0

Documentation

Overview

Package EditorResourcePicker provides methods for working with EditorResourcePicker object instances.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Advanced

type Advanced = class

Advanced exposes a 1:1 low-level instance of the class, undocumented, for those who know what they are doing.

type Any

type Any interface {
	gd.IsClass
	AsEditorResourcePicker() Instance
}

type Implementation

type Implementation = implementation

Implementation implements Interface with empty methods.

type Instance

type Instance [1]gdclass.EditorResourcePicker

This [Control] node is used in the editor's Inspector dock to allow editing of [Resource] type properties. It provides options for creating, loading, saving and converting resources. Can be used with [EditorInspectorPlugin] to recreate the same behavior. [b]Note:[/b] This [Control] does not include any editor for the resource, as editing is controlled by the Inspector dock itself or sub-Inspectors.

See [Interface] for methods that can be overridden by a [Class] that extends it.

%!(EXTRA string=EditorResourcePicker)

var Nil Instance

Nil is a nil/null instance of the class. Equivalent to the zero value.

func New

func New() Instance

func (Instance) AsBoxContainer

func (self Instance) AsBoxContainer() BoxContainer.Instance

func (Instance) AsCanvasItem

func (self Instance) AsCanvasItem() CanvasItem.Instance

func (Instance) AsContainer

func (self Instance) AsContainer() Container.Instance

func (Instance) AsControl

func (self Instance) AsControl() Control.Instance

func (Instance) AsEditorResourcePicker

func (self Instance) AsEditorResourcePicker() Instance

func (Instance) AsHBoxContainer

func (self Instance) AsHBoxContainer() HBoxContainer.Instance

func (Instance) AsNode

func (self Instance) AsNode() Node.Instance

func (Instance) AsObject

func (self Instance) AsObject() [1]gd.Object

func (Instance) BaseType

func (self Instance) BaseType() string

func (Instance) Editable

func (self Instance) Editable() bool

func (Instance) EditedResource

func (self Instance) EditedResource() [1]gdclass.Resource

func (Instance) GetAllowedTypes

func (self Instance) GetAllowedTypes() []string

Returns a list of all allowed types and subtypes corresponding to the [member base_type]. If the [member base_type] is empty, an empty list is returned.

func (Instance) OnResourceChanged

func (self Instance) OnResourceChanged(cb func(resource [1]gdclass.Resource))

func (Instance) OnResourceSelected

func (self Instance) OnResourceSelected(cb func(resource [1]gdclass.Resource, inspect bool))

func (Instance) SetBaseType

func (self Instance) SetBaseType(value string)

func (Instance) SetEditable

func (self Instance) SetEditable(value bool)

func (Instance) SetEditedResource

func (self Instance) SetEditedResource(value [1]gdclass.Resource)

func (Instance) SetToggleMode

func (self Instance) SetToggleMode(value bool)

func (Instance) SetTogglePressed

func (self Instance) SetTogglePressed(pressed bool)

Sets the toggle mode state for the main button. Works only if [member toggle_mode] is set to [code]true[/code].

func (Instance) ToggleMode

func (self Instance) ToggleMode() bool

func (*Instance) UnsafePointer

func (self *Instance) UnsafePointer() unsafe.Pointer

func (Instance) Virtual

func (self Instance) Virtual(name string) reflect.Value

type Interface

type Interface interface {
	//This virtual method is called when updating the context menu of [EditorResourcePicker]. Implement this method to override the "New ..." items with your own options. [param menu_node] is a reference to the [PopupMenu] node.
	//[b]Note:[/b] Implement [method _handle_menu_selected] to handle these custom items.
	SetCreateOptions(menu_node Object.Instance)
	//This virtual method can be implemented to handle context menu items not handled by default. See [method _set_create_options].
	HandleMenuSelected(id int) bool
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL