From c332f8f349b74bd4cd353832b1f867b2cf6b1d79 Mon Sep 17 00:00:00 2001 From: lvv83 Date: Sat, 29 Aug 2015 14:26:26 +0300 Subject: [PATCH] Provide localization for Loading Solution Dialog --- data/resources/StringResources.resx | 6 ++++++ src/Main/SharpDevelop/Project/ProjectService.cs | 4 ++-- src/Main/SharpDevelop/Project/SolutionLoader.cs | 3 ++- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/data/resources/StringResources.resx b/data/resources/StringResources.resx index d9f7fd02b78..960398fccf0 100644 --- a/data/resources/StringResources.resx +++ b/data/resources/StringResources.resx @@ -8446,4 +8446,10 @@ Press Esc to cancel this operation. Enable App.xaml parsing + + Loading solution... + + + Loading ${ProjectName} + \ No newline at end of file diff --git a/src/Main/SharpDevelop/Project/ProjectService.cs b/src/Main/SharpDevelop/Project/ProjectService.cs index 1b5da97114f..ea0bd527473 100644 --- a/src/Main/SharpDevelop/Project/ProjectService.cs +++ b/src/Main/SharpDevelop/Project/ProjectService.cs @@ -172,7 +172,7 @@ void OpenSolutionOrProjectInternal(FileName fileName) void OpenSolutionInternal(FileName fileName) { ISolution solution; - using (var progress = AsynchronousWaitDialog.ShowWaitDialog("Loading Solution...")) { + using (var progress = AsynchronousWaitDialog.ShowWaitDialog("${res:ICSharpCode.SharpDevelop.Gui.Dialogs.LoadingSolutionForm.Title}")) { solution = LoadSolutionFile(fileName, progress); @@ -226,7 +226,7 @@ void OpenProjectInternal(FileName fileName) // Use try-finally block to dispose the solution unless it is opened successfully. try { if (SD.FileSystem.FileExists(solutionFile)) { - using (var progress = AsynchronousWaitDialog.ShowWaitDialog("Loading Solution...")) { + using (var progress = AsynchronousWaitDialog.ShowWaitDialog("${res:ICSharpCode.SharpDevelop.Gui.Dialogs.LoadingSolutionForm.Title}")) { solution = LoadSolutionFile(solutionFile, progress); } // If LoadSolutionFile() throws ProjectLoadException, let that be handled by the ObservedLoad. diff --git a/src/Main/SharpDevelop/Project/SolutionLoader.cs b/src/Main/SharpDevelop/Project/SolutionLoader.cs index f98253f9fe8..460effefa7e 100644 --- a/src/Main/SharpDevelop/Project/SolutionLoader.cs +++ b/src/Main/SharpDevelop/Project/SolutionLoader.cs @@ -155,7 +155,8 @@ public void ReadSolution(Solution solution, IProgressMonitor progress) } else { // Load project: projectInfo.ActiveProjectConfiguration = projectInfo.ConfigurationMapping.GetProjectConfiguration(solution.ActiveConfiguration); - progress.TaskName = "Loading " + projectInfo.ProjectName; + var parseArgs = new[] { new StringTagPair("ProjectName", projectInfo.ProjectName) }; + progress.TaskName = StringParser.Parse("${res:ICSharpCode.SharpDevelop.Gui.Dialogs.LoadingSolutionForm.LoadProject}", parseArgs); using (projectInfo.ProgressMonitor = progress.CreateSubTask(1.0 / projectCount)) { solutionItem = LoadProjectWithErrorHandling(projectInfo); }