-
-
Notifications
You must be signed in to change notification settings - Fork 314
/
GuiDesktopControl.cs
33 lines (31 loc) · 955 Bytes
/
GuiDesktopControl.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
namespace MonoGame.Extended.NuclexGui.Controls
{
/// <summary>Control used to represent the desktop</summary>
public class GuiDesktopControl : GuiControl
{
/// <summary>Initializes a new control</summary>
public GuiDesktopControl()
{
}
/// <summary>True if the mouse is currently hovering over a GUI element</summary>
public bool IsMouseOverGui
{
get
{
if (MouseOverControl == null)
return false;
return !ReferenceEquals(MouseOverControl, this);
}
}
/// <summary>Whether the GUI holds ownership of the input devices</summary>
public bool IsInputCaptured
{
get
{
if (ActivatedControl == null)
return false;
return !ReferenceEquals(ActivatedControl, this);
}
}
}
}