Esempio n. 1
0
 public void Initialize(ActionSheetOption option, Action <ActionSheetOptionViewController> onItemClicked)
 {
     this.option     = option;
     this.image      = option.icon;
     this.message    = option.message;
     m_OnItemClicked = onItemClicked;
 }
        private void AddOption(ActionSheetOption options)
        {
            var go = Instantiate(m_Template, m_ComponentContainer, false);
            var vc = go.GetComponent <ActionSheetOptionViewController>();

            vc.Initialize(options, OnActionSheetOptionClicked);
            m_Options.Add(vc);
        }
Esempio n. 3
0
        private void AddOption(ActionSheetOption option)
        {
            var instance = Instantiate(m_ActionSheetTemplate, m_ActionSheetContainer, false);
            ActionSheetOptionViewController vc = instance.GetComponent <ActionSheetOptionViewController>();

            vc.Initialize(option, OnActionSheetOptionClicked);
            m_Options.Add(vc);
        }