Skip to content

Commit 2cf6117

Browse files
committed
reenable saving Settings/InputBox
1 parent 38e54cd commit 2cf6117

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

Intersect.Client.Core/Interface/Game/EventWindow.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,8 +154,7 @@ private EventWindow(Canvas gameCanvas, Dialog dialog) : base(gameCanvas, nameof(
154154
}
155155
}
156156

157-
// var optionLimit = Math.Max(1, visibleOptions.Length);
158-
// Name = $"EventDialogWindow_{optionLimit}Response{(optionLimit == 1 ? string.Empty : 's')}";
157+
// Name = $"{nameof(EventWindow)}_{Math.Max(1, visibleOptions.Length)}";
159158
// LoadJsonUi(GameContentManager.UI.InGame, Graphics.Renderer?.GetResolutionString());
160159

161160
SkipRender();

Intersect.Client.Core/Interface/Shared/InputBox.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
using Intersect.Client.Core;
12
using Intersect.Client.Framework.File_Management;
23
using Intersect.Client.Framework.Graphics;
34
using Intersect.Client.Framework.Gwen;
@@ -6,6 +7,7 @@
67
using Intersect.Client.Framework.Gwen.Control.EventArguments.InputSubmissionEvent;
78
using Intersect.Client.Localization;
89
using Intersect.Framework;
10+
using Intersect.Framework.Reflection;
911

1012
namespace Intersect.Client.Interface.Shared;
1113

@@ -604,7 +606,8 @@ public override void Dispose()
604606

605607
protected override void EnsureInitialized()
606608
{
607-
// LoadJsonUi(GameContentManager.UI.Shared, Graphics.Renderer?.GetResolutionString());
609+
Name = $"{GetType().GetName(qualified: false)}_{InputType}";
610+
LoadJsonUi(GameContentManager.UI.Shared, Graphics.Renderer?.GetResolutionString());
608611

609612
Show();
610613
Focus();

Intersect.Client.Core/Interface/Shared/SettingsWindow.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1164,6 +1164,6 @@ private void CancelPendingChangesButton_Clicked(Base sender, MouseButtonState ar
11641164

11651165
protected override void EnsureInitialized()
11661166
{
1167-
// LoadJsonUi(stage: UI.Shared, resolution: Graphics.Renderer?.GetResolutionString());
1167+
LoadJsonUi(stage: UI.Shared, resolution: Graphics.Renderer?.GetResolutionString());
11681168
}
11691169
}

0 commit comments

Comments
 (0)