Update submodule, removal of window AddToScreen.

This commit is contained in:
Pieter-Jan Briers
2019-07-18 22:49:49 +02:00
parent a9a99c1821
commit ce1eab9181
16 changed files with 6 additions and 29 deletions

View File

@@ -61,7 +61,6 @@ namespace Content.Client.Construction
Placement = (PlacementManager)IoCManager.Resolve<IPlacementManager>();
Placement.PlacementCanceled += OnPlacementCanceled;
HideOnClose = true;
Title = "Construction";
Visible = false;

View File

@@ -50,8 +50,6 @@ namespace Content.Client
_escapeMenu.OnClose += () => _gameHud.EscapeButtonDown = false;
_escapeMenu.AddToScreen();
var escapeMenuCommand = InputCmdHandler.FromDelegate(Enabled);
_inputManager.SetInputCommand(EngineKeyFunctions.EscapeMenu, escapeMenuCommand);
@@ -68,7 +66,7 @@ namespace Content.Client
private void Enabled(ICommonSession session)
{
if (_escapeMenu.Visible)
if (_escapeMenu.IsOpen)
{
if (_escapeMenu.IsAtFront())
{

View File

@@ -43,8 +43,6 @@ namespace Content.Client.GameObjects.Components.Actor
var uiComponents = Owner.GetAllComponents<ICharacterUI>();
Window = new CharacterWindow(uiComponents);
Window.OnClose += () => _gameHud.CharacterButtonDown = false;
Window.AddToScreen();
}
/// <summary>
@@ -98,7 +96,6 @@ namespace Content.Client.GameObjects.Components.Actor
public CharacterWindow(IEnumerable<ICharacterUI> windowComponents)
{
Title = "Character";
HideOnClose = true;
Visible = false;
_contentsVBox = new VBoxContainer();

View File

@@ -44,7 +44,6 @@ namespace Content.Client.GameObjects.Components.Construction
ConstructionMenu = new ConstructionMenu {Owner = this};
ConstructionMenu.OnClose += () => _gameHud.CraftingButtonDown = false;
}
ConstructionMenu.AddToScreen();
_gameHud.CraftingButtonVisible = true;
_gameHud.CraftingButtonToggled = b =>

View File

@@ -32,7 +32,6 @@ namespace Content.Client.GameObjects.Components.Power
MarginRight = 426.0f, MarginBottom = 270.0f
};
_window.OnClose += Close;
_window.AddToScreen();
_breakerButton = _window.BreakerButton;
_breakerButton.OnPressed += _ => SendMessage(new ApcToggleMainBreakerMessage());
@@ -153,7 +152,7 @@ namespace Content.Client.GameObjects.Components.Power
externalStatus.AddChild(externalStatusLabel);
externalStatus.AddChild(ExternalPowerStateLabel);
rows.AddChild(externalStatus);
var charge = new HBoxContainer("Charge");
var chargeLabel = new Label("Label") { Text = "Charge:" };
ChargeBar = new ProgressBar("Charge")

View File

@@ -28,7 +28,6 @@ namespace Content.Client.GameObjects.Components.Power
Title = "Power Debug Tool",
};
LastWindow.Contents.AddChild(new Label() { Text = msg.Data });
LastWindow.AddToScreen();
LastWindow.Open();
break;
}

View File

@@ -52,10 +52,8 @@ namespace Content.Client.GameObjects.Components.Research
menu.OnClose += Close;
menu.AddToScreen();
menu.Populate();
menu.PopulateMaterials();
queueMenu.AddToScreen();
menu.QueueButton.OnPressed += (args) => { queueMenu.OpenCentered(); };

View File

@@ -81,7 +81,6 @@ namespace Content.Client.GameObjects.Components.Storage
/// </summary>
private void OpenUI()
{
Window.AddToScreen();
Window.Open();
}
@@ -119,7 +118,6 @@ namespace Content.Client.GameObjects.Components.Storage
base.Initialize();
Title = "Storage Item";
HideOnClose = true;
Visible = false;
RectClipContent = true;

View File

@@ -36,7 +36,7 @@ namespace Content.Client.GameObjects.EntitySystems
var menu = characterInterface.Window;
if (menu.Visible)
if (menu.IsOpen)
{
if (menu.IsAtFront())
{

View File

@@ -36,7 +36,7 @@ namespace Content.Client.GameObjects.EntitySystems
var menu = constructor.ConstructionMenu;
if (menu.Visible)
if (menu.IsOpen)
{
if (menu.IsAtFront())
{

View File

@@ -48,7 +48,6 @@ namespace Content.Client.Research
base.Initialize();
IoCManager.InjectDependencies(this);
HideOnClose = true;
Title = "Lathe Menu";
Visible = false;

View File

@@ -29,7 +29,6 @@ namespace Content.Client.Research
{
base.Initialize();
HideOnClose = true;
Title = "Lathe Queue";
Visible = false;

View File

@@ -49,10 +49,8 @@ namespace Content.Client.UserInterface
{
Visible = false
};
optionsMenu.AddToScreen();
Resizable = false;
HideOnClose = true;
Title = "Menu";
@@ -95,14 +93,12 @@ namespace Content.Client.UserInterface
private void OnSpawnEntitiesButtonClicked(BaseButton.ButtonEventArgs args)
{
var window = new EntitySpawnWindow(_placementManager, _prototypeManager, _resourceCache);
window.AddToScreen();
window.OpenToLeft();
}
private void OnSpawnTilesButtonClicked(BaseButton.ButtonEventArgs args)
{
var window = new TileSpawnWindow(__tileDefinitionManager, _placementManager, _resourceCache);
window.AddToScreen();
window.OpenToLeft();
}

View File

@@ -113,14 +113,13 @@ namespace Content.Client.UserInterface
_buttonCraftingMenu.OnToggled += args => CraftingButtonToggled?.Invoke(args.Pressed);
_tutorialWindow = new TutorialWindow();
_tutorialWindow.AddToScreen();
_tutorialWindow.OnClose += () => _buttonTutorial.Pressed = false;
}
private void ButtonTutorialOnOnToggled(BaseButton.ButtonToggledEventArgs obj)
{
if (_tutorialWindow.Visible)
if (_tutorialWindow.IsOpen)
{
if (!_tutorialWindow.IsAtFront())
{

View File

@@ -29,9 +29,6 @@ You can ask on Discord or heck, just write it in OOC! We'll catch it.";
public TutorialWindow()
{
HideOnClose = true;
Visible = false;
var scrollContainer = new ScrollContainer();
Contents.AddChild(scrollContainer);