2017年3月18日 星期六

CustomMenu

CustomMenu


class in UnityEngine.UI.iMenu / Inherits from:IMenu

Description

Customize button position menu.

CustomMenu can assist you when you want to create a menu of irregularly arranged buttons such as a map menu.


Inherited members



Variables


allCells All of the buttons in this menu can be pre-placed in the array, or right click on the menu of inspector by selecting "CollectAllCells" to collect all the buttons under the menu of GameObject.

clickMode This is cursor and touch click button mode which determines how your buttons are executed.

isDisableFocus Whether the button that is not enabled is operational.

isFocused Whether the menu is currently focused.

operaing Whether the option function of switch and click  is enable.


Public Functions


AddOnChangeOptionListener Listen the menu to toggle options.

AddOnClickListener Listen the menu click operation.

ClearCells Clear all buttons for this menu.

CreateCells Dynamically create all buttons.It's only useful in dynamic creation mode.

Defocus Out of focus, lose focus from all buttons.

GetCurrentIndex The menu currently focuses on the index.

OperaSwitch "Operaing" switch.

IsCellOperable Confirm that the specified button is operational.

RemoveAllOnChangeOptionListener Remove all "when switching options" listener.

RemoveAllOnClickListener Remove all "when clicking options" listener.

RemoveOnChangeOptionListener Remove the "when switching options" listener.

RemoveOnClickListener Remove the "when clicking options" listener.

ResetToFirstOption Reset the option index to the first enabled button position.

SetCellDisplay Button display switch.

SetCellEnable Button to enable the switch.

SetCellContent Set button display content.

SetCellsContent Set all buttons display content.

SetFocus Sets the index to focus on the previous operation.The return value is the focus index value.




Scripting

沒有留言:

張貼留言