Skip to content

Commit

Permalink
Added different error messages to HandleCleanBlobs(), HandleCleanRegi…
Browse files Browse the repository at this point in the history
…stry() and HandleServiceRepair() methods.

Also, synchronized error levels between message boxes and logs.
  • Loading branch information
xvitaly committed Apr 16, 2024
1 parent 65fa290 commit 9505645
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 11 deletions.
26 changes: 22 additions & 4 deletions src/srcrepair/AppStrings.Designer.cs

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

10 changes: 8 additions & 2 deletions src/srcrepair/AppStrings.resx
Original file line number Diff line number Diff line change
Expand Up @@ -495,12 +495,15 @@
<data name="PS_BwBusy" xml:space="preserve">
<value>Cleanup targets are not yet available! Please try again in 10 seconds.</value>
</data>
<data name="PS_CleanException" xml:space="preserve">
<value>An error occurred during cleanup. Perhaps you have not enough rights for doing this.</value>
<data name="PS_CleanBlobsException" xml:space="preserve">
<value>An error occurred during the blobs removal! Perhaps you have not enough rights for doing this.</value>
</data>
<data name="PS_CleanInProgress" xml:space="preserve">
<value>Cleaning up...</value>
</data>
<data name="PS_CleanRegistryException" xml:space="preserve">
<value>An error occurred during the registry entries removal! Perhaps you have not enough rights for doing this.</value>
</data>
<data name="PS_CleanupErr" xml:space="preserve">
<value>Error occured while deleting files. Some files were not deleted!</value>
</data>
Expand Down Expand Up @@ -543,6 +546,9 @@
<data name="PS_SeqCompleted" xml:space="preserve">
<value>The cleanup has been successfully completed. Steam will run in recovery mode right now!</value>
</data>
<data name="PS_ServiceRepairException" xml:space="preserve">
<value>An error occurred while trying to run the Steam Service automatic repair procedure! Perhaps you have not enough rights for doing this.</value>
</data>
<data name="QI_Excpt" xml:space="preserve">
<value>An error occured during file installation. Please try again later!</value>
</data>
Expand Down
10 changes: 8 additions & 2 deletions src/srcrepair/AppStrings.ru.resx
Original file line number Diff line number Diff line change
Expand Up @@ -495,12 +495,15 @@
<data name="PS_BwBusy" xml:space="preserve">
<value>Цели для очистки ещё не были построены! Пожалуйста повторите попытку через 10 секунд.</value>
</data>
<data name="PS_CleanException" xml:space="preserve">
<value>Произошла ошибка во время процедуры очистки. Возможно, у вас отсутствуют необходимые права для этого действия.</value>
<data name="PS_CleanBlobsException" xml:space="preserve">
<value>Произошла ошибка во время работы процедуры очистки blob-файлов! Возможно, у вас отсутствуют необходимые права для этого действия.</value>
</data>
<data name="PS_CleanInProgress" xml:space="preserve">
<value>Выполняется...</value>
</data>
<data name="PS_CleanRegistryException" xml:space="preserve">
<value>Произошла ошибка во время удаления записей, хранящихся в реестре! Возможно, у вас отсутствуют необходимые права для этого действия.</value>
</data>
<data name="PS_CleanupErr" xml:space="preserve">
<value>Во время удаления файлов произошла ошибка. Некоторые файлы не были удалены!</value>
</data>
Expand Down Expand Up @@ -543,6 +546,9 @@
<data name="PS_SeqCompleted" xml:space="preserve">
<value>Очистка успешно выполнена. Steam будет запущен в режиме восстановления прямо сейчас!</value>
</data>
<data name="PS_ServiceRepairException" xml:space="preserve">
<value>Произошла ошибка при попытке запуска автоматического восстановления Steam Service! Возможно, у вас отсутствуют необходимые права для этого действия.</value>
</data>
<data name="QI_Excpt" xml:space="preserve">
<value>Произошла ошибка во время установки выбранного файла!</value>
</data>
Expand Down
6 changes: 3 additions & 3 deletions src/srcrepair/FrmMainW.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1025,7 +1025,7 @@ private void HandleCleanBlobs()
catch (Exception Ex)
{
Logger.Error(Ex, DebugStrings.AppDbgExClnBlobs);
MessageBox.Show(AppStrings.PS_CleanException, Properties.Resources.AppName, MessageBoxButtons.OK, MessageBoxIcon.Error);
MessageBox.Show(AppStrings.PS_CleanBlobsException, Properties.Resources.AppName, MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}
Expand All @@ -1044,7 +1044,7 @@ private void HandleCleanRegistry()
catch (Exception Ex)
{
Logger.Error(Ex, DebugStrings.AppDbgExClnReg);
MessageBox.Show(AppStrings.PS_CleanException, Properties.Resources.AppName, MessageBoxButtons.OK, MessageBoxIcon.Warning);
MessageBox.Show(AppStrings.PS_CleanRegistryException, Properties.Resources.AppName, MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}
Expand All @@ -1067,7 +1067,7 @@ private void HandleServiceRepair()
catch (Exception Ex)
{
Logger.Error(Ex, DebugStrings.AppDbgExSvcRepair);
MessageBox.Show(AppStrings.PS_CleanException, Properties.Resources.AppName, MessageBoxButtons.OK, MessageBoxIcon.Warning);
MessageBox.Show(AppStrings.PS_ServiceRepairException, Properties.Resources.AppName, MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}
Expand Down

0 comments on commit 9505645

Please sign in to comment.