Skip to content

Commit

Permalink
add localization strings and its applies on updater
Browse files Browse the repository at this point in the history
  • Loading branch information
marona42 committed Mar 2, 2021
1 parent d1eae1c commit c229d1d
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 6 deletions.
8 changes: 4 additions & 4 deletions SCTools/SCTool_Redesigned/Pages/updatePatcher.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -91,10 +91,10 @@ private async void TryUpdate()
catch (Exception exception) //TODO: write log and label text, but not on MessageBox
{
if (exception is HttpRequestException)
MessageBox.Show("다운로드 에러:" + '\n' + exception.Message, "업데이트 에러");
MessageBox.Show($"{Properties.Resources.Localization_Download_ErrorTitle}" + '\n' + exception.Message, $"{Properties.Resources.Localization_Update_ErrorTitle}");
else
MessageBox.Show("다운로드 에러:", "업데이트 에러");
MessageBox.Show("어쨌든 에러:", "업데이트 에러");
MessageBox.Show($"{Properties.Resources.Localization_Download_ErrorTitle}", $"{Properties.Resources.Localization_Update_ErrorTitle}");
MessageBox.Show($"{Properties.Resources.MSG_Title_GeneralError}:{exception.Message}", $"{Properties.Resources.Localization_Update_ErrorTitle}");
}
finally
{
Expand All @@ -108,7 +108,7 @@ private static bool InstallScheduledUpdate()
if (result != InstallUpdateStatus.Success)
{
//_logger.Error($"Failed launch install update: {result}");
MessageBox.Show("업데이트 실패" + @" - " + result.ToString("d"), App.Name); //FOR DEBUG
MessageBox.Show($"{Properties.Resources.Localization_Update_ErrorTitle}" + @" - " + result.ToString("d"), App.Name); //FOR DEBUG
return false;
}
return true;
Expand Down
14 changes: 12 additions & 2 deletions SCTools/SCTool_Redesigned/Properties/Resources.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions SCTools/SCTool_Redesigned/Properties/Resources.ko-KR.resx
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,9 @@
<data name="Localization_Uninstall_WarningTitle" xml:space="preserve">
<value>제거 경고</value>
</data>
<data name="Localization_Update_ErrorTitle" xml:space="preserve">
<value>업데이트 에러</value>
</data>
<data name="Localization_Verify_ErrorText" xml:space="preserve">
<value>패키지 보안 확인에 실패하였습니다. 다른 것을 시도하거나 패키지 관리자에게 문의하십시오.</value>
</data>
Expand Down
3 changes: 3 additions & 0 deletions SCTools/SCTool_Redesigned/Properties/Resources.resx
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,9 @@
<data name="Localization_Uninstall_WarningTitle" xml:space="preserve">
<value>Uninstall warning</value>
</data>
<data name="Localization_Update_ErrorTitle" xml:space="preserve">
<value>Update Error</value>
</data>
<data name="Localization_Verify_ErrorText" xml:space="preserve">
<value>Package security verification is not passed. Please try another or contact with package owner.</value>
</data>
Expand Down

0 comments on commit c229d1d

Please sign in to comment.