Esempio n. 1
0
        internal virtual void Layout(RxTheme theme = null)
        {
            if (!IsLayoutCycleRequired)
            {
                return;
            }

            IsLayoutCycleRequired = false;

            if (_invalidated)
            {
                //System.Diagnostics.Debug.WriteLine($"{this}->Layout(Invalidated)");
                var oldChildren = Children;
                _children = null;
                MergeChildrenFrom(oldChildren);
                _invalidated = false;
            }

            if (!_isMounted && Parent != null)
            {
                OnMount();
            }

            if (_stateChanged)
            {
                OnUpdate();
            }

            foreach (var child in Children)
            {
                child.Layout(theme);
            }
        }
Esempio n. 2
0
        internal virtual void Layout(RxTheme theme = null /*, VisualNode parent = null*/)
        {
            //if (parent != null)
            //    Parent = parent;

            if (!IsLayoutCycleRequired)
            {
                return;
            }

            IsLayoutCycleRequired = false;

            if (_invalidated)
            {
                //System.Diagnostics.Debug.WriteLine($"{this}->Layout(Invalidated)");
                var oldChildren = Children;
                _children = null;
                MergeChildrenFrom(oldChildren);
                _invalidated = false;
            }

            if (!_isMounted && Parent != null)
            {
                OnMount();
            }

            CommitAnimations();

            AnimateThis();

            if (_stateChanged)
            {
                OnUpdate();
            }

            foreach (var child in Children.Where(_ => _.IsLayoutCycleRequired))
            {
                child.Layout(theme);
            }
        }
Esempio n. 3
0
 public static RxTheme UseTheme <T>(this IEnumerable <T> node, RxTheme theme) where T : VisualNode
 {
     theme.Add(node.ToArray());
     return(theme);
 }
Esempio n. 4
0
 public static RxTheme UseTheme <T>(this T node, RxTheme theme) where T : VisualNode
 {
     theme.Add(node);
     return(theme);
 }
Esempio n. 5
0
 internal sealed override void Layout(RxTheme theme)
 {
     base.Layout(this);
 }
Esempio n. 6
0
 internal sealed override void Layout(RxTheme theme /*, VisualNode parent = null*/)
 {
     base.Layout(this /*, parent*/);
 }
Esempio n. 7
0
 internal override void Layout(RxTheme theme = null)
 {
     _theme = theme;
     base.Layout(theme);
 }
Esempio n. 8
0
 internal override void Layout(RxTheme theme = null /*, VisualNode parent = null*/)
 {
     _theme = theme;
     base.Layout(theme /*, parent*/);
 }