/// <summary>
        /// 是否能够布局该子项
        /// </summary>
        /// <param name="child">面板子元素</param>
        /// <returns>
        /// 是否能够布局该子项
        /// </returns>
        public override bool CanLayoutChild(TimelinePanelChild child)
        {
            var returnValue = true;
            var testRect = child.LayoutRect;

            // orientation specific... adjust the child Y for this layout container
            testRect.Y = LayoutRect.Y;
            
            foreach (var existingChild in Children)
            {
                if (existingChild.LayoutRect.IntersectsWith(testRect))
                {
                    returnValue = false;
                    break;
                }
            }

            return returnValue;
        }
Beispiel #2
0
        /// <summary>
        /// 是否能够布局该子项
        /// </summary>
        /// <param name="child">面板子元素</param>
        /// <returns>
        /// 是否能够布局该子项
        /// </returns>
        public override bool CanLayoutChild(TimelinePanelChild child)
        {
            var returnValue = true;
            var testRect    = child.LayoutRect;

            // orientation specific... adjust the child Y for this layout container
            testRect.Y = LayoutRect.Y;

            foreach (var existingChild in Children)
            {
                if (existingChild.LayoutRect.IntersectsWith(testRect))
                {
                    returnValue = false;
                    break;
                }
            }

            return(returnValue);
        }
 /// <summary>
 /// 是否能够布局该子项
 /// </summary>
 /// <param name="child">面板子元素</param>
 /// <returns>
 /// 是否能够布局该子项
 /// </returns>
 public override bool CanLayoutChild(TimelinePanelChild child)
 {
     return(true);
 }
 /// <summary>
 /// 是否能够布局该子项
 /// </summary>
 /// <param name="child">面板子元素</param>
 /// <returns>
 /// 是否能够布局该子项
 /// </returns>
 public override bool CanLayoutChild(TimelinePanelChild child)
 {
     return true;
 }