Make CharacterWindow bigger to accomodate traitor objectives (#5850)
* Move MinSize to the same place where the window is created * Adds BoxContainer to a ScrollContainer so it can resize in case of more objectives * Slight adjustment to ensure the convention is followed * Changes MinSize to SetSize so it can be resized to lower sizes and to stop it resizing every time you reopen it
This commit is contained in:
@@ -41,7 +41,11 @@ namespace Content.Client.CharacterInterface
|
|||||||
{
|
{
|
||||||
Orientation = LayoutOrientation.Vertical
|
Orientation = LayoutOrientation.Vertical
|
||||||
};
|
};
|
||||||
Contents.AddChild(contentsVBox);
|
|
||||||
|
var mainScrollContainer = new ScrollContainer { };
|
||||||
|
mainScrollContainer.AddChild(contentsVBox);
|
||||||
|
|
||||||
|
Contents.AddChild(mainScrollContainer);
|
||||||
|
|
||||||
windowComponents.Sort((a, b) => ((int) a.Priority).CompareTo((int) b.Priority));
|
windowComponents.Sort((a, b) => ((int) a.Priority).CompareTo((int) b.Priority));
|
||||||
foreach (var element in windowComponents)
|
foreach (var element in windowComponents)
|
||||||
|
|||||||
@@ -48,7 +48,11 @@ namespace Content.Client.CharacterInterface
|
|||||||
if (comp.UIComponents.Count == 0)
|
if (comp.UIComponents.Count == 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
comp.Window = new CharacterInterfaceComponent.CharacterWindow(comp.UIComponents);
|
comp.Window = new CharacterInterfaceComponent.CharacterWindow(comp.UIComponents)
|
||||||
|
{
|
||||||
|
SetSize = (545, 400)
|
||||||
|
};
|
||||||
|
|
||||||
comp.Window.OnClose += () => _gameHud.CharacterButtonDown = false;
|
comp.Window.OnClose += () => _gameHud.CharacterButtonDown = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user