Recovered subtitle files are now saved in their own subfolder.
Originally committed to SVN as r468.
This commit is contained in:
parent
72abf003b1
commit
14dbb8c4a4
3 changed files with 20 additions and 4 deletions
|
@ -95,6 +95,7 @@ Please visit http://aegisub.net to download latest version
|
||||||
- Fixed the default resolution for video display and resolution resampler when the script's field is blank. (AMZ)
|
- Fixed the default resolution for video display and resolution resampler when the script's field is blank. (AMZ)
|
||||||
- Stopping audio playback will now stop video playback as well. (AMZ)
|
- Stopping audio playback will now stop video playback as well. (AMZ)
|
||||||
- Implemented sorting of subtitles by start time. (AMZ)
|
- Implemented sorting of subtitles by start time. (AMZ)
|
||||||
|
- Recovered subtitle files are now saved in their own subfolder. (AMZ)
|
||||||
|
|
||||||
|
|
||||||
= 1.09 beta - 2006.01.16 ===========================
|
= 1.09 beta - 2006.01.16 ===========================
|
||||||
|
|
|
@ -137,8 +137,15 @@ bool AegisubApp::OnInit() {
|
||||||
// Unhandled exception
|
// Unhandled exception
|
||||||
void AegisubApp::OnUnhandledException() {
|
void AegisubApp::OnUnhandledException() {
|
||||||
// Attempt to recover file
|
// Attempt to recover file
|
||||||
wxFileName orig(AssFile::top->filename);
|
wxFileName origfile(AssFile::top->filename);
|
||||||
wxString filename = folderName + orig.GetName() + _T(".RECOVER.ass");
|
wxString path = Options.AsText(_T("Auto recovery path"));
|
||||||
|
if (path.IsEmpty()) path = folderName;
|
||||||
|
wxFileName dstpath(path);
|
||||||
|
if (!dstpath.IsAbsolute()) path = AegisubApp::folderName + path;
|
||||||
|
path += _T("/");
|
||||||
|
dstpath.Assign(path);
|
||||||
|
if (!dstpath.DirExists()) wxMkdir(path);
|
||||||
|
wxString filename = folderName + origfile.GetName() + _T(".RECOVER.ass");
|
||||||
AssFile::top->Save(filename,false,false);
|
AssFile::top->Save(filename,false,false);
|
||||||
|
|
||||||
// Inform user of crash
|
// Inform user of crash
|
||||||
|
@ -150,8 +157,15 @@ void AegisubApp::OnUnhandledException() {
|
||||||
// Fatal exception
|
// Fatal exception
|
||||||
void AegisubApp::OnFatalException() {
|
void AegisubApp::OnFatalException() {
|
||||||
// Attempt to recover file
|
// Attempt to recover file
|
||||||
wxFileName orig(AssFile::top->filename);
|
wxFileName origfile(AssFile::top->filename);
|
||||||
wxString filename = folderName + orig.GetName() + _T(".RECOVER.ass");
|
wxString path = Options.AsText(_T("Auto recovery path"));
|
||||||
|
if (path.IsEmpty()) path = folderName;
|
||||||
|
wxFileName dstpath(path);
|
||||||
|
if (!dstpath.IsAbsolute()) path = AegisubApp::folderName + path;
|
||||||
|
path += _T("/");
|
||||||
|
dstpath.Assign(path);
|
||||||
|
if (!dstpath.DirExists()) wxMkdir(path);
|
||||||
|
wxString filename = path + origfile.GetName() + _T(".RECOVER.ass");
|
||||||
AssFile::top->Save(filename,false,false);
|
AssFile::top->Save(filename,false,false);
|
||||||
|
|
||||||
// Stack walk
|
// Stack walk
|
||||||
|
|
|
@ -238,6 +238,7 @@ void OptionsManager::LoadDefaults() {
|
||||||
SetInt(_T("Auto save every seconds"),60);
|
SetInt(_T("Auto save every seconds"),60);
|
||||||
SetText(_T("Auto backup path"),_T("autoback"));
|
SetText(_T("Auto backup path"),_T("autoback"));
|
||||||
SetText(_T("Auto save path"),_T("autosave"));
|
SetText(_T("Auto save path"),_T("autosave"));
|
||||||
|
SetText(_T("Auto recovery path"),_T("recovered"));
|
||||||
SetInt(_T("Autoload linked files"),2);
|
SetInt(_T("Autoload linked files"),2);
|
||||||
|
|
||||||
SetText(_T("Text actor separator"),_T(":"));
|
SetText(_T("Text actor separator"),_T(":"));
|
||||||
|
|
Loading…
Reference in a new issue