Build 0.20.8.0
This commit is contained in:
@@ -35,6 +35,13 @@ namespace Barotrauma.Items.Components
|
||||
if (GuiFrame == null) { return; }
|
||||
originalMaxSize = GuiFrame.RectTransform.MaxSize;
|
||||
originalRelativeSize = GuiFrame.RectTransform.RelativeSize;
|
||||
CreateGUI();
|
||||
}
|
||||
|
||||
protected override void CreateGUI()
|
||||
{
|
||||
if (GuiFrame == null) { return; }
|
||||
|
||||
CheckForLabelOverlap();
|
||||
var content = new GUICustomComponent(new RectTransform(Vector2.One, GuiFrame.RectTransform), DrawConnections, null)
|
||||
{
|
||||
@@ -43,8 +50,8 @@ namespace Barotrauma.Items.Components
|
||||
content.RectTransform.SetAsFirstChild();
|
||||
|
||||
//prevents inputs from going through the GUICustomComponent to the drag handle
|
||||
dragArea = new GUIFrame(new RectTransform(GuiFrame.Rect.Size - GUIStyle.ItemFrameMargin, GuiFrame.RectTransform, Anchor.Center)
|
||||
{ AbsoluteOffset = GUIStyle.ItemFrameOffset }, style: null);
|
||||
dragArea = new GUIFrame(new RectTransform(GuiFrame.Rect.Size - GUIStyle.ItemFrameMargin, GuiFrame.RectTransform, Anchor.Center)
|
||||
{ AbsoluteOffset = GUIStyle.ItemFrameOffset }, style: null);
|
||||
}
|
||||
|
||||
public void TriggerRewiringSound()
|
||||
@@ -121,12 +128,6 @@ namespace Barotrauma.Items.Components
|
||||
}
|
||||
}
|
||||
|
||||
protected override void OnResolutionChanged()
|
||||
{
|
||||
if (GuiFrame == null) { return; }
|
||||
CheckForLabelOverlap();
|
||||
}
|
||||
|
||||
private void CheckForLabelOverlap()
|
||||
{
|
||||
GuiFrame.RectTransform.MaxSize = originalMaxSize;
|
||||
|
||||
Reference in New Issue
Block a user