Exemplo n.º 1
0
        private void SetChooserOption(PreciseManeuverDropdownItem item)
        {
            if (!(item is PreciseManeuverPagerItem))
            {
                return;
            }
            var pageritem = item as PreciseManeuverPagerItem;

            m_Control.ReplaceTextComponentWithTMPro(pageritem.NodeIdx.GetComponent <Text> ())?.
            Invoke(m_Control.getLocalizedNodeln(pageritem.Index + 1));
            m_Control.ReplaceTextComponentWithTMPro(pageritem.NodeTime.GetComponent <Text> ())?.
            Invoke(m_Control.getManeuverTime(pageritem.Index));
            m_Control.ReplaceTextComponentWithTMPro(pageritem.NodedV.GetComponent <Text> ())?.
            Invoke(m_Control.getManeuverDV(pageritem.Index));
            m_Control.ReplaceTextComponentWithTMPro(pageritem.dVLabel.GetComponent <Text> ());
        }
Exemplo n.º 2
0
        public void SetControl(IPagerControl control)
        {
            m_Control = control;

            m_Chooser.UpdateDropdownCaption = SetChooserText;
            m_Chooser.UpdateDropdownOption  = SetChooserOption;
            chooserText = m_Control.ReplaceTextComponentWithTMPro(m_Chooser.CaptionArea.GetComponent <Text> ());
            UpdateGUI();
            m_Control.RegisterUpdateAction(UpdateGUI);
        }