Fix cp1250 decoding, log unsupported loads

The repositories resolved GetEncoding(1250) in their constructors, before
anything registered CodePagesEncodingProvider - reads fell back to Latin-1 and
Polish characters came out as mojibake.
This commit is contained in:
maj00r
2026-09-04 22:06:59 +02:00
parent 673cda57d7
commit b33d7697a0
13 changed files with 113 additions and 92 deletions

View File

@@ -20,6 +20,7 @@ using StarterNG.Domain;
using StarterNG.Application;
using StarterNG.Domain.Sceneries;
using StarterNG.Presentation.Scenarios;
using StarterNG.Infrastructure.Adapters;
namespace StarterNG.Views;
@@ -708,7 +709,7 @@ public partial class Scenarios : UserControl
try
{
timetableContent.Text = File.ReadAllText(path, Encoding.GetEncoding(1250));
timetableContent.Text = File.ReadAllText(path, LegacyText.CodePage1250);
UpdateTimetableTab(true);
}
catch