Fix: Displays Subtitle seems to be empty - try to re-save if you're working on a valid subtitle! for every language when trying to save empty subtitle thanks to @marb99

This commit is contained in:
ivandrofly 2014-06-12 01:45:40 +01:00
parent 87a9ed813b
commit a23f5f6a47
3 changed files with 7 additions and 3 deletions

View File

@ -966,7 +966,9 @@ Email: mailto:nikse.dk@gmail.com</AboutText1>
<SavedOriginalSubtitleX>Saved original subtitle {0}</SavedOriginalSubtitleX>
<FileOnDiskModified>file on disk modified</FileOnDiskModified>
<OverwriteModifiedFile>Overwrite the file {0} modified at {1} {2}{3} with current file loaded from disk at {4} {5}?</OverwriteModifiedFile>
<UnableToSaveSubtitleX>Unable to save subtitle file {0}</UnableToSaveSubtitleX>
<UnableToSaveSubtitleX>Unable to save subtitle file {0}
Subtitle seems to be empty - try to re-save if you're working on a valid subtitle!
</UnableToSaveSubtitleX>
<BeforeNew>Before new</BeforeNew>
<New>New</New>
<BeforeConvertingToX>Before converting to {0}</BeforeConvertingToX>

View File

@ -3495,7 +3495,7 @@ namespace Nikse.SubtitleEdit.Forms
{
if (allText.Trim().Length == 0)
{
MessageBox.Show(string.Format(_language.UnableToSaveSubtitleX, _fileName) + Environment.NewLine + Environment.NewLine + "Subtitle seems to be empty - try to re-save if you're working on a valid subtitle!");
MessageBox.Show(string.Format(_language.UnableToSaveSubtitleX, _fileName), String.Empty, MessageBoxButtons.OK, MessageBoxIcon.Stop);
return DialogResult.Cancel;
}
File.WriteAllText(_fileName, allText, currentEncoding);

View File

@ -981,7 +981,9 @@ Email: mailto:nikse.dk@gmail.com</AboutText1>
<SavedOriginalSubtitleX>Legenda original guardada {0}</SavedOriginalSubtitleX>
<FileOnDiskModified>Ficheiro modificado no disco</FileOnDiskModified>
<OverwriteModifiedFile>Substituir o ficheiro {0} modificado em {1} {2}{3} pelo ficheiro actual carregado do disco em {4} {5}?</OverwriteModifiedFile>
<UnableToSaveSubtitleX>Não foi possível guardar a legenda {0}</UnableToSaveSubtitleX>
<UnableToSaveSubtitleX>Não foi possível guardar a legenda {0}
parece estar vazia!
</UnableToSaveSubtitleX>
<BeforeNew>Antes de novo</BeforeNew>
<New>Novo</New>
<BeforeConvertingToX>Convertendo anterior para {0}</BeforeConvertingToX>