class HubMenuUtils
{

	public static function SetMenuData( menuButton : inkWidgetRef, identifier : HubMenuItems, parentIdentifier : HubMenuItems, fullscreenName : CName, icon : CName, labelKey : CName, optional userData : IScriptable ) : MenuItemController
	{
		var menuItemLogicController : MenuItemController;
		var data : MenuData;
		data.label = GetLocalizedTextByKey( labelKey );
		data.icon = icon;
		data.fullscreenName = fullscreenName;
		data.identifier = ( ( Int32 )( identifier ) );
		data.parentIdentifier = ( ( Int32 )( parentIdentifier ) );
		data.userData = userData;
		menuItemLogicController = ( ( MenuItemController )( inkWidgetRef.GetController( menuButton ) ) );
		menuItemLogicController.Init( data );
		return menuItemLogicController;
	}

	public static function SetMenuData( menuButton : inkWidgetRef, const data : ref< MenuData > ) : MenuItemController
	{
		var menuItemLogicController : MenuItemController;
		menuItemLogicController = ( ( MenuItemController )( inkWidgetRef.GetController( menuButton ) ) );
		menuItemLogicController.Init( data );
		return menuItemLogicController;
	}

	public static function SetMenuHyperlinkData( menuButton : inkWidgetRef, identifier : HubMenuItems, parentIdentifier : HubMenuItems, fullscreenName : CName, icon : CName, labelKey : CName, optional userData : IScriptable ) : MenuItemController
	{
		var menuItemLogicController : MenuItemController;
		menuItemLogicController = SetMenuData( menuButton, identifier, parentIdentifier, fullscreenName, icon, labelKey, userData );
		menuItemLogicController.SetHyperlink( true );
		return menuItemLogicController;
	}

	public static function SetRadialMenuData( menuButton : inkWidgetRef, identifier : HubMenuItems, parentIdentifier : HubMenuItems, fullscreenName : CName, icon : CName, labelKey : CName, optional userData : IScriptable ) : RadialMenuItemController
	{
		var menuItemLogicController : RadialMenuItemController;
		var data : MenuData;
		data.label = GetLocalizedTextByKey( labelKey );
		data.icon = icon;
		data.fullscreenName = fullscreenName;
		data.identifier = ( ( Int32 )( identifier ) );
		data.parentIdentifier = ( ( Int32 )( parentIdentifier ) );
		data.userData = userData;
		menuItemLogicController = ( ( RadialMenuItemController )( inkWidgetRef.GetController( menuButton ) ) );
		menuItemLogicController.Init( data );
		return menuItemLogicController;
	}

	public static function SetRadialMenuData( menuButton : inkWidgetRef, const data : ref< MenuData > ) : RadialMenuItemController
	{
		var menuItemLogicController : RadialMenuItemController;
		menuItemLogicController = ( ( RadialMenuItemController )( inkWidgetRef.GetController( menuButton ) ) );
		menuItemLogicController.Init( data );
		return menuItemLogicController;
	}

	public static function SetRadialMenuHyperlinkData( menuButton : inkWidgetRef, identifier : HubMenuItems, parentIdentifier : HubMenuItems, fullscreenName : CName, icon : CName, labelKey : CName, optional userData : IScriptable ) : RadialMenuItemController
	{
		var menuItemLogicController : RadialMenuItemController;
		menuItemLogicController = SetRadialMenuData( menuButton, identifier, parentIdentifier, fullscreenName, icon, labelKey, userData );
		menuItemLogicController.SetHyperlink( true );
		return menuItemLogicController;
	}

}

