mirror of
https://github.com/space-wizards/RobustToolbox.git
synced 2026-09-01 17:47:24 +02:00
* Removed the Interfaces folder. * All objects inside the GameObjects subfolders are now in the GameObjects namespace. * Added a Resharper DotSettings file to mark the GameObjects subfolders as not providing namespaces. * Simplified Robust.client.Graphics namespace. * Automated remove redundant using statements.
43 lines
1.0 KiB
C#
43 lines
1.0 KiB
C#
using Robust.Client.Graphics;
|
|
using Robust.Client.Input;
|
|
using Robust.Client.UserInterface.Controls;
|
|
using Robust.Shared.IoC;
|
|
using Robust.Shared.Maths;
|
|
using Robust.Shared.Timing;
|
|
|
|
namespace Robust.Client.UserInterface.CustomControls
|
|
{
|
|
internal class DebugInputPanel : PanelContainer
|
|
{
|
|
[Dependency] private readonly IInputManager _inputManager = default!;
|
|
|
|
private readonly Label _label;
|
|
|
|
public DebugInputPanel()
|
|
{
|
|
IoCManager.InjectDependencies(this);
|
|
|
|
PanelOverride = new StyleBoxFlat
|
|
{
|
|
BackgroundColor = new Color(67, 105, 255, 138),
|
|
};
|
|
|
|
PanelOverride.SetContentMarginOverride(StyleBox.Margin.All, 5);
|
|
|
|
AddChild(_label = new Label());
|
|
}
|
|
|
|
protected override void FrameUpdate(FrameEventArgs args)
|
|
{
|
|
base.FrameUpdate(args);
|
|
|
|
if (!VisibleInTree)
|
|
{
|
|
return;
|
|
}
|
|
|
|
_label.Text = string.Join("\n", _inputManager.DownKeyFunctions);
|
|
}
|
|
}
|
|
}
|