Exemplo n.º 1
0
 public override void PreConvert()
 {
     foreach (var t in Childs.ToList())
     {
         t.PreConvert();
     }
     foreach (var t in Objects.ToList())
     {
         t.PreConvert();
     }
     base.PreConvert();
 }
Exemplo n.º 2
0
        /// <summary>
        /// Will transfer all childs to destination <see cref="ScreenNode" />
        /// </summary>
        /// <param name="destination">Destination <see cref="ScreenNode" /> that all Childs should be transfered to</param>
        /// <param name="direction"><see cref="TransferDirection" /> of the transfer</param>
        public virtual void TransferAllChilds(ScreenNode destination, TransferDirection direction)
        {
            foreach (var child in Childs.ToList())
            {
                if (child.Style == NodeStyle.FullscreenOne)
                {
                    child.Style = NodeStyle.Tile;
                }

                if (destination.TransferNode(null, child, direction, child == FocusNode))
                {
                    DisconnectChild(child);
                }
                else
                {
                    Log.Error($"{nameof(ScreenNode)}.{nameof(TransferAllChilds)} Could not transfer child node \"{child}\"");
                }
            }
        }