コード例 #1
0
        /// <summary>
        /// Sets the expanded bounds.
        /// </summary>
        private void SetExpandedBounds()
        {
            Debug.WriteLine("_expandedView Bounds: " + _expandedView.Bounds);
            _expandedView.ForceLayout();
            double x     = CollapsableFrame.Margin.Left;
            double y     = _expandedView.Bounds.Y;
            double width = -1;

            if (Parent != null)
            {
                width = ((ListView)Parent).Bounds.Width - CollapsableFrame.Margin.HorizontalThickness;
            }
            double height = _expandedView.Bounds.Height; // Math.Round((_expandedView.Bounds.Height + ExpandedCloseLabel.Bounds.Height), 0, MidpointRounding.AwayFromZero); //* 1.35

            _expandedBounds = new Rectangle(x, y, width, height);
            Debug.WriteLine("set _expandedBounds = " + _expandedBounds.ToString());
        }