public override bool Init(bool force = false)
        {
            if (base.Init(force))
            {
                ValidateSpawnParent();
                CollectChildren();
                if (PoolSize > 0)
                {
                    _pooledGameObjects = new SizedStack <T>(PoolSize);
                }
                return(true);
            }

            return(false);
        }
 /// <summary>
 /// Initializes the instance with the given size
 /// </summary>
 /// <exception cref="ArgumentException">size is smaller than 1</exception>
 /// <param name="size">The number of actions to record</param>
 public WpfHistory(int size)
 {
     if (size == Size)
     {
         _undoStack = new SizedStack<IAction>(size);
         _redoStack = new SizedStack<IAction>(size);
     }
     else
     {
         Size = size;
     }
 }