Component:ContextMenuSubmenu: Difference between revisions

From Resonite Wiki
Automated: update Fields, Categories
add more info
 
Line 1: Line 1:
<!--T:1-->
<!--T:1-->
{{stub}}
{{Infobox Component
{{Infobox Component
|Image=ContextMenuSubmenuComponent.png
|Image=ContextMenuSubmenuComponent.png
|Name=Context Menu Submenu
|Name=Context Menu Submenu
}}
}}
 
{{stub}}
The ContextMenuSubmenu component can be used in combination with any button component to make said button open a custom context menu when clicked. This is commonly done on avatars, using a [[RootContextMenuItem (Component)|RootContextMenuItem]] as the button, but can also be used on anything else.
The ContextMenuSubmenu component can be used in combination with any button component to make said button open a custom context menu when clicked.  


<!--T:2-->
<!--T:2-->
== Fields ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|ItemsRoot|Slot| All [[ContextMenuItemSource (Component)|ContextMenuItemSources]] on slots under this one will be included in the submenu.
|ItemsRoot|Slot| All [[Component:ContextMenuItemSource|Context Menu Item Sources]] on slots immediately under this one will be included in the submenu.
|SearchWholeHierarchy|Bool| {{stub}}
|SearchWholeHierarchy|Bool| Display all items under <code>ItemsRoot</slot> including sub slots, not just ones immediately under.
|DisableFlick|Bool| {{stub}}
|DisableFlick|Bool| Whether to allow opening of the sub menu by clicking on the context menu center and moving it to this component's [[Component:ContextMenuItemSource|Context Menu Item Source]] on the same slot.
|SpeedOverride|'''[[Type:Nullable`1|Nullable`1]]&lt;[[Type:Float|Float]]&gt;'''|TypeAdv3=true|
|SpeedOverride|'''[[Type:Nullable`1|Nullable`1]]&lt;[[Type:Float|Float]]&gt;'''|TypeAdv3=true| Override the speed at which the new context menu will open.
|CounterClockwise|Bool| Whether the items should be arranged clockwise or counter-clockwise in the submenu.
|CounterClockwise|Bool| Whether the items should be arranged clockwise or counter-clockwise in the submenu.
|KeepPosition|Bool| When set, the context menu will stay in the same place as the submenu opens. Otherwise, the context menu will recenter on the user's laser.
|KeepPosition|Bool| When set, the context menu will stay in the same place as the submenu opens. Otherwise, the context menu will recenter on the user's laser.
|Hidden|Bool| If set, the submenu is only visible to the user that opened it, (The button to open it)
|Hidden|Bool| If set, the submenu is only visible to the user that opened it.
}}
}}


<!--T:3-->
<!--T:3-->
== Usage ==
== Usage ==
{{stub}}
Attach this component to a [[Slot|slot]] and attach a [[Component:ContextMenuItemSource|Context Menu Item Source]] along side it. Providing a slot to


<!--T:4-->
<!--T:4-->
== Examples ==
== Examples ==
{{stub}}
This is commonly used on avatars, using a [[RootContextMenuItem (Component)|RootContextMenuItem]] as the button, but can also be used on anything else.


<!--T:5-->
<!--T:5-->
Line 32: Line 31:
{{stub}}
{{stub}}


[[Category:ComponentStubs]]
[[Category:Components:Radiant UI:Context Menu{{#translation:}}|Context Menu Submenu]]
[[Category:Components:Radiant UI:Context Menu{{#translation:}}|Context Menu Submenu]]
[[Category:Components{{#translation:}}|Context Menu Submenu]]
[[Category:Components{{#translation:}}|Context Menu Submenu]]

Latest revision as of 17:36, 16 October 2024

Component image 
Context Menu Submenu component as seen in the Scene Inspector


This article or section is a Stub. You can help the Resonite Wiki by expanding it.


The ContextMenuSubmenu component can be used in combination with any button component to make said button open a custom context menu when clicked.

Fields

Fields
Name Type Description
persistent Bool Determines whether or not this item will be saved to the server.
UpdateOrder Int Controls the order in which this component is updated.
Enabled Bool Controls whether or not this component is enabled.
ItemsRoot Slot All Context Menu Item Sources on slots immediately under this one will be included in the submenu.
SearchWholeHierarchy Bool Display all items under ItemsRoot</slot> including sub slots, not just ones immediately under.
DisableFlick Bool Whether to allow opening of the sub menu by clicking on the context menu center and moving it to this component's Context Menu Item Source on the same slot.
SpeedOverride Nullable`1<Float> Override the speed at which the new context menu will open.
CounterClockwise Bool Whether the items should be arranged clockwise or counter-clockwise in the submenu.
KeepPosition Bool When set, the context menu will stay in the same place as the submenu opens. Otherwise, the context menu will recenter on the user's laser.
Hidden Bool If set, the submenu is only visible to the user that opened it.

Usage

Attach this component to a slot and attach a Context Menu Item Source along side it. Providing a slot to

Examples

This is commonly used on avatars, using a RootContextMenuItem as the button, but can also be used on anything else.

Related Issues

This article or section is a Stub. You can help the Resonite Wiki by expanding it.