コード例 #1
0
        /// <summary>
        /// Starts the borderTimer
        /// </summary>
        /// <param name="color"></param>
        public void ShowBorder(Color color)
        {
            BorderForm bf;

            if (borderForm == null || borderForm.Width != Width)
            {
                Bitmap b = TableFactory.GetBorderBitmap(color, site, Width, Height);
                bf         = TableFactory.MakeBorderForm(Width, Height, b, color);
                bf.TopMost = true;
                borderForm = bf;
            }
            else
            {
                bf = borderForm;
            }

            Rectangle rect = new Rectangle();

            Win32.GetWindowRect(handle, ref rect);
            Win32.SetWindowPos((int)bf.Handle, 0, rect.Left, rect.Top, 0, 0, 0x201);
            bf.Show();

            if (Settings.FlashTable)
            {
                bf.Flash();
            }
            else
            {
                bf.NoFlash();
            }
        }
コード例 #2
0
        /// <summary>
        /// Creates a border form to be used on poker tables
        /// </summary>
        /// <param name="width"></param>
        /// <param name="height"></param>
        /// <param name="b"></param>
        /// <param name="color"></param>
        /// <returns></returns>
        public static BorderForm MakeBorderForm(int width, int height, Bitmap b, Color color)
        {
            BorderForm f = new BorderForm();

            f.Width  = width;
            f.Height = height;

            b.MakeTransparent(Color.Black);

            f.BackgroundImage = b;

            f.TransparencyKey = Color.Black;
            f.FlashColor      = color;

            return(f);
        }
コード例 #3
0
        /// <summary>
        /// Creates a border form to be used on poker tables
        /// </summary>
        /// <param name="width"></param>
        /// <param name="height"></param>
        /// <param name="b"></param>
        /// <param name="color"></param>
        /// <returns></returns>
        public static BorderForm MakeBorderForm(int width, int height, Bitmap b, Color color)
        {
            BorderForm f = new BorderForm();

            f.Width = width;
            f.Height = height;

            b.MakeTransparent(Color.Black);

            f.BackgroundImage = b;

            f.TransparencyKey = Color.Black;
            f.FlashColor = color;

            return f;
        }
コード例 #4
0
        /// <summary>
        /// Starts the borderTimer
        /// </summary>
        /// <param name="color"></param>
        public void ShowBorder(Color color)
        {
            BorderForm bf;

            if (borderForm == null || borderForm.Width != Width)
            {
                Bitmap b = TableFactory.GetBorderBitmap(color, site, Width, Height);
                bf = TableFactory.MakeBorderForm(Width, Height, b, color);
                bf.TopMost = true;
                borderForm = bf;
            }
            else
                bf = borderForm;

            Rectangle rect = new Rectangle();
            Win32.GetWindowRect(handle, ref rect);
            Win32.SetWindowPos((int)bf.Handle, 0, rect.Left, rect.Top, 0, 0, 0x201);
            bf.Show();

            if (Settings.FlashTable)
                bf.Flash();
            else
                bf.NoFlash();
        }