void UpdateCaptureFocus(int x, int y) { if (_top == null && _bottom == null) { return; } else if (_bottom == null) { //Console.WriteLine(string.Format("UpdateFocus: Top")); _target = _top; } else if (_top == null) { //Console.WriteLine(string.Format("UpdateFocus: Bottom")); _target = _bottom; } else { if (_top.IsOnRect(x, y)) { //Console.WriteLine(string.Format("UpdateFocus: Top")); _target = _top; } else if (_bottom.IsOnRect(x, y)) { //Console.WriteLine(string.Format("UpdateFocus: Bottom")); _target = _bottom; } } }
public override bool IsOnRect(int x, int y) { if (_drawable == null) { return(false); } else { return(_drawable.IsOnRect(x, y)); } }