classref: Sync with current master branch (543750a)

This commit is contained in:
Godot Organization
2023-06-03 03:19:05 +00:00
parent 2de3798d56
commit f9340bddb2
340 changed files with 1505 additions and 1258 deletions

View File

@@ -14,7 +14,7 @@ Control
**Inherited By:** :ref:`BaseButton<class_BaseButton>`, :ref:`ColorRect<class_ColorRect>`, :ref:`Container<class_Container>`, :ref:`GraphEdit<class_GraphEdit>`, :ref:`ItemList<class_ItemList>`, :ref:`Label<class_Label>`, :ref:`LineEdit<class_LineEdit>`, :ref:`MenuBar<class_MenuBar>`, :ref:`NinePatchRect<class_NinePatchRect>`, :ref:`Panel<class_Panel>`, :ref:`Range<class_Range>`, :ref:`ReferenceRect<class_ReferenceRect>`, :ref:`RichTextLabel<class_RichTextLabel>`, :ref:`Separator<class_Separator>`, :ref:`TabBar<class_TabBar>`, :ref:`TextEdit<class_TextEdit>`, :ref:`TextureRect<class_TextureRect>`, :ref:`Tree<class_Tree>`, :ref:`VideoStreamPlayer<class_VideoStreamPlayer>`
All user interface nodes inherit from Control. A control's anchors and offsets adapt its position and size relative to its parent.
Base class for all GUI controls. Adapts its position and size based on its parent control.
.. rst-class:: classref-introduction-group
@@ -1898,7 +1898,7 @@ This method should only be used to test the data. Process the data in :ref:`_dro
{
// Check position if it is relevant to you
// Otherwise, just check data
return data.VariantType == Variant.Type.Dictionary && data.AsGodotDictionary().Contains("expected");
return data.VariantType == Variant.Type.Dictionary && data.AsGodotDictionary().ContainsKey("expected");
}
@@ -1930,7 +1930,7 @@ Godot calls this method to pass you the ``data`` from a control's :ref:`_get_dra
public override bool _CanDropData(Vector2 atPosition, Variant data)
{
return data.VariantType == Variant.Type.Dictionary && dict.AsGodotDictionary().Contains("color");
return data.VariantType == Variant.Type.Dictionary && dict.AsGodotDictionary().ContainsKey("color");
}
public override void _DropData(Vector2 atPosition, Variant data)