From deea37e0bab734d6343d1528b1b73a3a830613cf Mon Sep 17 00:00:00 2001 From: Rodrigo Braz Monteiro Date: Sat, 26 Aug 2006 22:39:05 +0000 Subject: [PATCH] Fixed loading of sections with unexpected cases. Originally committed to SVN as r528. --- core/ass_file.cpp | 8 ++++---- core/changelog.txt | 7 ++++++- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/core/ass_file.cpp b/core/ass_file.cpp index 1507c575b..3969f6432 100644 --- a/core/ass_file.cpp +++ b/core/ass_file.cpp @@ -255,7 +255,7 @@ int AssFile::AddLine (wxString data,wxString group,int lasttime,bool &IsSSA,wxSt if (outGroup) *outGroup = group; // Attachment - if (group == _T("[Fonts]") || group == _T("[Graphics]")) { + if (group.Lower() == _T("[fonts]") || group.Lower() == _T("[graphics]")) { // Check if it's valid data size_t dataLen = data.Length(); bool validData = (dataLen > 0) && (dataLen <= 80); @@ -310,7 +310,7 @@ int AssFile::AddLine (wxString data,wxString group,int lasttime,bool &IsSSA,wxSt } // Dialogue - if (group == _T("[Events]")) { + if (group.Lower() == _T("[events]")) { if ((data.Left(9) == _T("Dialogue:") || data.Left(8) == _T("Comment:"))) { AssDialogue *diag = new AssDialogue(data,IsSSA); lasttime = diag->Start.GetMS(); @@ -327,7 +327,7 @@ int AssFile::AddLine (wxString data,wxString group,int lasttime,bool &IsSSA,wxSt } // Style - else if (group == _T("[V4+ Styles]")) { + else if (group.Lower() == _T("[v4+ styles]")) { if (data.Left(6) == _T("Style:")) { AssStyle *style = new AssStyle(data,IsSSA); entry = style; @@ -342,7 +342,7 @@ int AssFile::AddLine (wxString data,wxString group,int lasttime,bool &IsSSA,wxSt } // Script info - else if (group == _T("[Script Info]")) { + else if (group.Lower() == _T("[script info]")) { // Comment if (data.Left(1) == _T(";")) { // Skip stupid comments added by other programs diff --git a/core/changelog.txt b/core/changelog.txt index c86edbdce..c8cc3d464 100644 --- a/core/changelog.txt +++ b/core/changelog.txt @@ -1,7 +1,12 @@ Aegisub changelog Please visit http://aegisub.net to download latest version -= 1.10 beta - 2006.03.xx =========================== += 1.11 beta - 2006.xx.xx =========================== + +- Fixed loading of sections with unexpected cases. + + += 1.10 beta - 2006.08.07 =========================== - Always defaults to Audio Cache=1 (ram) now (Myrsloik) - Automation: Added xor(a,b) boolean logical function to utils.lua (jfs)