黄学彪
2020-05-19 e747e6d8524e3146bb48dc304a713f309966b1c6
ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/ListViewLayoutControls/VerticalFrameControl.cs
@@ -42,6 +42,13 @@
        public VerticalFrameControl(int i_rowSpace = 0)
        {
            rowSpace = Application.GetRealHeight(i_rowSpace);
#if iOS
            //自动偏移取消
            if (UIKit.UIDevice.CurrentDevice.CheckSystemVersion(11, 0))
            {
                (this.uiView as UIKit.UIScrollView).ContentInsetAdjustmentBehavior = UIKit.UIScrollViewContentInsetAdjustmentBehavior.Never;
            }
#endif
        }
        /// <summary>
@@ -97,7 +104,7 @@
        public void AdjustChidrenFrameHeight(FrameLayout frame, int buttomSpace)
        {
            //获取坐标底部最下面的那个控件的底部坐标
            int value = this.GetLocationMostLastViewBottom();
            int value = this.GetLocationMostLastViewBottom(frame);
            if (value != -1)
            {
                //调整桌布高度
@@ -114,7 +121,7 @@
        public void AdjustTableHeight()
        {
            //获取坐标底部最下面的那个控件的底部坐标
            int value = this.GetLocationMostLastViewBottom();
            int value = this.GetLocationMostLastViewBottom(this.m_frameTable);
            if (value != -1)
            {
                //调整桌布高度
@@ -135,9 +142,12 @@
                return;
            }
            //添加临时控件,直至可以滑动超过底部按钮
            int oldRowSpace = this.rowSpace;
            this.rowSpace = 0;
            var frameBackTemp = new FrameLayout();
            frameBackTemp.Height = ControlCommonResourse.BodyFrameHeight - btnTemp.Yaxis + Application.GetRealHeight(23);
            this.AddChidrenFrame(frameBackTemp);
            this.rowSpace = oldRowSpace;
        }
        /// <summary>
@@ -155,15 +165,15 @@
        /// 获取坐标底部最下面的那个控件的底部坐标
        /// </summary>
        /// <returns></returns>
        private int GetLocationMostLastViewBottom()
        private int GetLocationMostLastViewBottom(FrameLayout frame)
        {
            int bottomHeight = -1;
            if (this.m_frameTable == null) { return bottomHeight; }
            if (frame == null) { return bottomHeight; }
           
            for (int i = 0; i < this.m_frameTable.ChildrenCount; i++)
            for (int i = 0; i < frame.ChildrenCount; i++)
            {
                var child = this.m_frameTable.GetChildren(i);
                var child = frame.GetChildren(i);
                if (child.Bottom > bottomHeight)
                {
                    bottomHeight = child.Bottom;