Exemple #1
0
        static DrawDropDockForm()
        {
            _imgLeft    = ResourceService.GetResourceImage("page.img.DockDenotebitmap");
            _imageWidth = _imgLeft.Width;
            _imgTop     = new Bitmap(_imgLeft);
            _imgTop.RotateFlip(RotateFlipType.Rotate90FlipNone);
            _imgRight = new Bitmap(_imgTop);
            _imgRight.RotateFlip(RotateFlipType.Rotate90FlipNone);
            _imgBottom = new Bitmap(_imgRight);
            _imgBottom.RotateFlip(RotateFlipType.Rotate90FlipNone);
            _imgInto = ResourceService.GetResourceImage("page.img.DockDenoteIntobitmap");

            _halfOpacityForm = new HalfOpacityForm();
        }
Exemple #2
0
        static private HalfOpacityForm GetInstance()
        {
            ///先尝试在对象池中取,若取不到则new一个
            HalfOpacityForm usingForm = null;

            if (_listForm.Count > 0)
            {
                usingForm = _listForm[0];

                _listForm.RemoveAt(0);
            }
            else
            {
                usingForm = new HalfOpacityForm();
            }

            ///将对象加入到正在使用的列表中
            _listUsingForm.Add(usingForm);

            return(usingForm);
        }
Exemple #3
0
        static public void ShowForm(int x, int y, int width, int height)
        {
            HalfOpacityForm form = GetInstance();

            Utility.DllImport.SetWindowShow(form, null, x, y, width, height);
        }