Esempio n. 1
0
        /*--------------------------------------------------------------------------------------------*/
        public virtual void TreeUpdate()
        {
            HoverRendererUpdater rendUp  = GetComponent <HoverRendererUpdater>();
            HoverIndicator       rendInd = rendUp.ActiveRenderer.GetIndicator();

            rendInd.Controllers.Set(HoverIndicator.HighlightProgressName, this);
            rendInd.Controllers.Set(HoverIndicator.SelectionProgressName, this);

            rendInd.HighlightProgress = Mathf.Max(rendInd.HighlightProgress, MinHightlightProgress);
            rendInd.SelectionProgress = Mathf.Max(rendInd.SelectionProgress, MinSelectionProgress);

            Controllers.TryExpireControllers();
        }
Esempio n. 2
0
        /*--------------------------------------------------------------------------------------------*/
        private void UpdateRendererIndicator(HoverRenderer pRenderer,
                                             HoverItemHighlightState pHighState, HoverItemSelectionState pSelState)
        {
            HoverIndicator rendInd = pRenderer.GetIndicator();

            rendInd.Controllers.Set(HoverIndicator.HighlightProgressName, this);
            rendInd.Controllers.Set(HoverIndicator.SelectionProgressName, this);

            rendInd.HighlightProgress = pHighState.MaxHighlightProgress;
            rendInd.SelectionProgress = pSelState.SelectionProgress;

            if (pSelState.WasSelectedThisFrame)
            {
                rendInd.LatestSelectionTime = DateTime.UtcNow;
            }
        }
Esempio n. 3
0
        ////////////////////////////////////////////////////////////////////////////////////////////////
        /*--------------------------------------------------------------------------------------------*/
        private void UpdateIndicatorChildren()
        {
            TreeUpdater tree = GetComponent <TreeUpdater>();

            for (int i = 0; i < tree.TreeChildrenThisFrame.Count; i++)
            {
                TreeUpdater    child    = tree.TreeChildrenThisFrame[i];
                HoverIndicator childInd = child.GetComponent <HoverIndicator>();

                if (childInd == null)
                {
                    continue;
                }

                childInd.Controllers.Set(HighlightProgressName, this);
                childInd.Controllers.Set(SelectionProgressName, this);

                childInd.HighlightProgress   = HighlightProgress;
                childInd.SelectionProgress   = SelectionProgress;
                childInd.LatestSelectionTime = LatestSelectionTime;
            }
        }