Bricklayer.Client.Game.CheckControlPos C# (CSharp) Method

CheckControlPos() public method

public CheckControlPos ( Control c, Point pos ) : bool
c Control
pos Point
return bool
        public bool CheckControlPos(Control c, Point pos)
        {
            // Is this a visible control other than the MainWindow?
            // Is the mouse cursor within this control's boundaries?
            if (c.Visible && !c.Passive && c != MainWindow &&
                pos.X >= c.AbsoluteRect.Left && pos.X <= c.AbsoluteRect.Right &&
                pos.Y >= c.AbsoluteRect.Top && pos.Y <= c.AbsoluteRect.Bottom)
            {
                // Yes, mouse cursor is over this control.
                return false;
            }
            else
            {
                return true;
            }
        }