亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? zonesequence.cs

?? Magic Library 1.7,有說明文檔
?? CS
?? 第 1 頁 / 共 4 頁
字號:
            {
                // Give it all the space
                _windows[0].ZoneArea = 100m;
            }
            else
            {
                // Is there any space to reallocate?
                if (w.ZoneArea > 0)
                {
                    // Total up all the values
                    Decimal totalAllocated = 0m;

                    // How much space should we add to each of the others
                    Decimal freedSpace = w.ZoneArea / (_windows.Count - 1);

                    foreach(Window entry in _windows)
                    {
                        if (entry != w)
                        {
                            // We only retain a sensible level of precision
                            Decimal newSpace = Decimal.Round(entry.ZoneArea + freedSpace, _spacePrecision);                            

                            // Assign back new space
                            entry.ZoneArea = newSpace;
                            
                            // Total up all space so far 
                            totalAllocated += newSpace;
                        }
                    }

                    // Look for minor errors due not all fractions can be accurately represented in binary!
                    if (totalAllocated > 100m)
                    {
                        Decimal correction = totalAllocated - 100m;

                        // Remove from first entry
                        foreach(Window entry in _windows)
                        {
                            if (entry != w)
                            {
                                // Apply correction to this window
                                entry.ZoneArea = totalAllocated - 100m;
                                break;
                            }
                        }
                    }
                    else if (totalAllocated < 100m)
                    {
                        Decimal correction = 100m - totalAllocated;

                        // Remove from first entry
                        foreach(Window entry in _windows)
                        {
                            if (entry != w)
                            {
                                // Apply correction to this window
                                entry.ZoneArea += 100m - totalAllocated;
                                break;
                            }
                        }
                    }

                    // Window no longer has any space
                    w.ZoneArea = 0m;
                }
            }
        }

        protected void RepositionControls()
        {
			// Caller has requested that this call be ignored
			if (_suppressReposition)
			{
				_suppressReposition = false;
				return;
			}

            Rectangle clientRect = this.ClientRectangle;

            RepositionZoneBar(ref clientRect);

            if (_windows.Count > 0)
            {
                // Space available for allocation
                int space;
				
                // Starting position of first control 
                int delta;

                if (_direction == Direction.Vertical)
                {
                    space = clientRect.Height;
                    delta = clientRect.Top;
                }
                else
                {
                    space = clientRect.Width;
                    delta = clientRect.Left;
                }

                // Ensure this is not negative
                if (space < 0)
                    space = 0;

                int barSpace = 0;
                int allocation = space;

                // Create temporary array of working values
                Position[] positions = new Position[Controls.Count - 1];

                // Pass 1, allocate all the space needed for each ResizeBar and the 
                //         minimal amount of space that each Window requests. 
                AllocateMandatorySizes(ref positions, ref barSpace, ref space);

                // If there any more space left
                if (space > 0)
                {
                    // Pass 2, allocate any space left over according to the request percent 
                    //         area that each Window would like to achieve.
                    AllocateRemainingSpace(ref positions, space);
                }

                // Pass 3, reposition the controls according to allocated values.
                RepositionControls(ref positions, clientRect, delta);
            }
        }

        protected void AllocateMandatorySizes(ref Position[] positions, ref int barSpace, ref int space)
        {
            // Process each control (except last which is the Zone level ResizeBar)
            for(int index=0; index<(Controls.Count - 1); index++)
            {
                ResizeBar bar = Controls[index] as ResizeBar;

                if (bar != null)
                {
                    // Length needed is depends on direction 
                    positions[index].length = bar.Length;

                    // Add up how much space was allocated to ResizeBars
                    barSpace += positions[index].length;
                }
                else
                {
                    Window w = Controls[index] as Window;

                    if (w != null)
                    {
                        Size minimal = w.MinimalSize;

                        // Length needed is depends on direction 
                        if (_direction == Direction.Vertical)
                            positions[index].length = minimal.Height;
                        else
                            positions[index].length = minimal.Width;
                    }
                }

                // Reduce available space by that just allocated
                space -= positions[index].length;
            }			
        }

        protected void AllocateRemainingSpace(ref Position[] positions, int windowSpace)
        {
            // Space allocated so far
            int allocated = 0;

            // Process each control (except last which is the Zone level ResizeBar)
            for(int index=0; index<(Controls.Count - 1); index++)
            {
                Window w = Controls[index] as Window;

                // If no window is maximized then as long as the control is a window we enter the if statement,
                // If a window is maximized then we only enter the if statement if this is the maximzied one
                if ((w != null) && ((_maximizedWindow == null) || ((_maximizedWindow != null) && (_maximizedWindow == w))))
                {
                    // How much of remaining space does the Window request to have?
                    int extra;
					
                    if (_maximizedWindow == null)				
                    {
                        extra = (int)(windowSpace / 100m * w.ZoneArea);

                        // Is this the last Window to be positioned?
                        if (index == (Controls.Count - 1))
                        {
                            // Use up all the remaining space, this handles the case of 
                            // the above vector calculation giving rounding errors so that
                            // the last element needs adusting to fill exactly all the 
                            // available space
                            extra = windowSpace - allocated;
                        }
                    }
                    else
                    {
                        extra = windowSpace - allocated;
                    }

                    // Add the extra space to any existing space it has
                    positions[index].length += extra;

                    // Keep count of all allocated so far
                    allocated += extra;
                }
            }
        }

        protected void RepositionControls(ref Position[] positions, Rectangle clientRect, int delta)
        {
            // Process each control (except last which is the Zone level ResizeBar)
            for(int index=0; index<(Controls.Count - 1); index++)
            {
                int newDelta = positions[index].length;

                ResizeBar bar = Controls[index] as ResizeBar;

                if (bar != null)
                {
                    if (_direction == Direction.Vertical)
                    {
                        // Set new position
                        bar.Location = new Point(clientRect.X, delta);
                        bar.Width = clientRect.Width;
                        bar.Height = newDelta;

                        // Move delta down to next position
                        delta += newDelta;
                    }
                    else
                    {
                        // Set new position
                        bar.Location = new Point(delta, clientRect.Y);
                        bar.Height = clientRect.Height;
                        bar.Width = newDelta;

                        // Move delta across to next position
                        delta += newDelta;
                    }
                }
                else
                {
                    Window w = Controls[index] as Window;

                    if (w != null)
                    {
                        if (newDelta == 0)
                            w.Hide();
                        else
                        {
                            // Set new position/size based on direction
                            if (_direction == Direction.Vertical)
                            {
                                w.Location = new Point(clientRect.X, delta);
                                w.Width = clientRect.Width;
                                w.Height = newDelta;
                            }
                            else
                            {
                                w.Location = new Point(delta, clientRect.Y);
                                w.Height = clientRect.Height;
                                w.Width = newDelta;
                            }

                            if (!w.Visible)
                                w.Show();

                            // Move delta to next position
                            delta += newDelta;
                        }
                    }
                }
            }			
        }

        protected void RepositionZoneBar(ref Rectangle clientRect)
        {
            Rectangle barRect;

            int length = _resizeBar.Length;
			
			// We only want a resizeBar when actually docked against an edge
			bool resizeBarPresent = ((this.Dock != DockStyle.Fill) && (this.Dock != DockStyle.None));

            // Define the correct direction for the resize bar and new Zone position
            switch(_state)
            {
                case State.DockLeft:
                    _resizeBar.Direction = Direction.Horizontal;
                    barRect = new Rectangle(this.Width - length, 0, length, this.Height);
					
					if (resizeBarPresent)
						clientRect.Width -= length;
                    break;
                case State.DockTop:
                    _resizeBar.Direction = Direction.Vertical;
                    barRect = new Rectangle(0, this.Height - length, this.Width, length);

					if (resizeBarPresent)
	                    clientRect.Height -= length;
                    break;
                case State.DockRight:
                    _resizeBar.Direction = Direction.Horizontal;
                    barRect = new Rectangle(0, 0, length, this.Height);

					if (resizeBarPresent)
					{
						clientRect.X += length;
						clientRect.Width -= length;
					}
                    break;
                case State.DockBottom:
                    _resizeBar.Direction = Direction.Vertical;
                    barRect = new Rectangle(0, 0, this.Width, length);

					if (resizeBarPresent)
					{
						clientRect.Y += length;
						clientRect.Height -= length;
					}
                    break;
                case State.Floating:
                default:
                    _resizeBar.Direction = Direction.Horizontal;
                    barRect = new Rectangle(0, 0, 0, 0);
                    break;
            }

			if (resizeBarPresent)
			{
				// Reposition the Zone level resize bar control
				_resizeBar.Location = new Point(barRect.X, barRect.Y);
				_resizeBar.Size = new Size(barRect.Width, barRect.Height);
				
				if (!_resizeBar.Visible)
					_resizeBar.Show();
			}
			else
			{
				if (_resizeBar.Visible)
					_resizeBar.Hide();
			}
        }

        protected override void OnResize(EventArgs e)
        {
            // Need to recalculate based on new window space
            RepositionControls();

            base.OnResize(e);
        }
    }
}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
91亚洲精华国产精华精华液| 极品少妇xxxx精品少妇偷拍| 色综合久久天天综合网| 自拍偷拍国产精品| 一本久久a久久精品亚洲| 一区二区三区不卡在线观看| 欧美午夜精品一区二区蜜桃| 午夜成人免费电影| 欧美白人最猛性xxxxx69交| 国产一区二区导航在线播放| 国产精品久久久99| 精品视频在线免费看| 免费观看在线色综合| 国产人妖乱国产精品人妖| www.日韩大片| 日本一道高清亚洲日美韩| 精品日韩99亚洲| 成人av免费网站| 日本免费新一区视频| 久久久久久久久久久电影| 91日韩精品一区| 日本色综合中文字幕| 国产精品久久久久久久久免费丝袜 | 精品国产sm最大网站免费看| 国产精品1区二区.| 亚洲午夜久久久久久久久电影院 | 精品国产一区二区三区久久影院| 国产成人精品亚洲午夜麻豆| 亚洲精品久久久蜜桃| 欧美日韩极品在线观看一区| 国产精品77777竹菊影视小说| 一区二区三区小说| 精品久久久久久无| 色久综合一二码| 国内精品写真在线观看| 一区二区视频在线| 久久久久高清精品| 欧美另类videos死尸| 国产iv一区二区三区| 午夜在线电影亚洲一区| 国产免费成人在线视频| 制服丝袜亚洲播放| 色伊人久久综合中文字幕| 黄网站免费久久| 亚洲国产日韩a在线播放性色| www国产精品av| 欧美视频在线观看一区| 丁香婷婷综合网| 伦理电影国产精品| 亚洲123区在线观看| 亚洲人成网站在线| 国产精品美女www爽爽爽| 精品国产乱码久久久久久蜜臀 | 91高清在线观看| 成人午夜免费视频| 精品亚洲aⅴ乱码一区二区三区| 亚洲国产精品久久久久婷婷884| 国产精品麻豆网站| 久久九九全国免费| 日韩欧美一区二区视频| 欧美久久久影院| 欧美在线观看视频一区二区| 91亚洲精华国产精华精华液| 丁香一区二区三区| 成人免费视频播放| 国产suv精品一区二区883| 国产乱子伦视频一区二区三区| 日韩成人av影视| 亚洲国产精品人人做人人爽| 一区二区在线电影| 亚洲精品国产精品乱码不99| 国产精品久久久久影院色老大| 久久精品一二三| 国产亚洲精久久久久久| 国产亚洲欧美中文| 日本一区二区电影| 国产精品入口麻豆原神| 国产精品无码永久免费888| 国产女人18毛片水真多成人如厕 | 爽爽淫人综合网网站| 性做久久久久久免费观看| 亚洲午夜视频在线观看| 午夜精品久久久久久久| 天天影视网天天综合色在线播放| 亚洲bdsm女犯bdsm网站| 日韩电影在线一区| 老司机精品视频在线| 国产一区二区三区美女| 粉嫩蜜臀av国产精品网站| av亚洲精华国产精华精| 色综合色综合色综合色综合色综合 | 美女尤物国产一区| 久久国产欧美日韩精品| 国产一区二区三区免费在线观看| 国模少妇一区二区三区| 成人做爰69片免费看网站| 91在线无精精品入口| 欧洲亚洲国产日韩| 91精品久久久久久久久99蜜臂 | 国产亚洲福利社区一区| 国产精品你懂的在线| 亚洲在线成人精品| 极品美女销魂一区二区三区| 国产毛片一区二区| 色999日韩国产欧美一区二区| 欧美三级一区二区| 久久精品视频网| 亚洲精品水蜜桃| 久久国产剧场电影| www.爱久久.com| 欧美日韩国产成人在线免费| 欧美电影精品一区二区| 中文字幕五月欧美| 日韩国产欧美一区二区三区| 国产一区二区三区在线观看免费| 99精品欧美一区二区蜜桃免费| 欧美日韩综合一区| 久久久777精品电影网影网| 亚洲一区在线视频观看| 国产精品一区免费在线观看| 色婷婷久久一区二区三区麻豆| 欧美一区二区在线免费播放| 中文字幕av一区二区三区高| 亚洲国产一区二区视频| 处破女av一区二区| 日韩一二在线观看| 亚洲精品五月天| 国产成人在线视频免费播放| 欧美性大战xxxxx久久久| 久久久久久久综合日本| 日韩电影免费在线观看网站| 99久久婷婷国产综合精品| 欧美不卡一区二区三区四区| 亚洲综合一区二区三区| 福利电影一区二区三区| 欧美一区欧美二区| 亚洲一卡二卡三卡四卡| 国产激情91久久精品导航 | 亚洲乱码日产精品bd| 国产黄色成人av| 欧美大片免费久久精品三p | 中文字幕永久在线不卡| 精彩视频一区二区三区| 欧美福利一区二区| 一区二区三区免费观看| 成人国产亚洲欧美成人综合网| 日韩欧美一级精品久久| 日韩在线一二三区| 欧美天堂亚洲电影院在线播放| 国产精品护士白丝一区av| 国产成人在线色| 久久日一线二线三线suv| 美女视频一区二区三区| 欧美日韩久久久一区| 一区二区三区高清| 日本久久电影网| 亚洲精品一二三| 色吧成人激情小说| 亚洲男人天堂av| 99精品国产一区二区三区不卡| 国产欧美一区二区精品性色| 国产在线一区二区| 久久男人中文字幕资源站| 激情欧美一区二区三区在线观看| 欧美久久高跟鞋激| 五月天精品一区二区三区| 欧美日韩国产美女| 午夜成人在线视频| 日韩欧美不卡一区| 久久99在线观看| 久久免费偷拍视频| 成人黄色777网| 亚洲另类在线制服丝袜| 欧美三区在线观看| 麻豆久久一区二区| 精品播放一区二区| 成人精品视频一区| 日韩美女视频一区| 在线免费亚洲电影| 偷拍日韩校园综合在线| 在线综合视频播放| 国内精品久久久久影院一蜜桃| 久久综合色鬼综合色| 波多野结衣中文字幕一区| 亚洲免费视频中文字幕| 欧美日韩精品三区| 久久精品国产久精国产| 国产午夜精品一区二区三区嫩草| 成人黄动漫网站免费app| 亚洲精品一二三| 欧美一二三区在线| 懂色av一区二区夜夜嗨| 亚洲一区二区欧美激情| 欧美一级日韩免费不卡| 国产白丝网站精品污在线入口| 亚洲精品免费一二三区| 91精品国产综合久久福利| 国产经典欧美精品| 亚洲最新视频在线播放| 精品国产制服丝袜高跟|