diff --git a/core/ass_file.cpp b/core/ass_file.cpp index 661ae5422..728d9ecab 100644 --- a/core/ass_file.cpp +++ b/core/ass_file.cpp @@ -36,6 +36,8 @@ //////////// // Includes +#include +#include #include "ass_file.h" #include "ass_dialogue.h" #include "ass_style.h" @@ -46,7 +48,6 @@ #include "text_file_reader.h" #include "text_file_writer.h" #include "version.h" -#include ////////////////////// AssFile ////////////////////// @@ -482,7 +483,7 @@ void AssFile::SaveSRT (wxString _filename,const wxString encoding) { void AssFile::DialogueToSRT(AssDialogue *current,std::list::iterator prev) { using std::list; AssDialogue *previous; - if (prev != NULL) previous = AssEntry::GetAsDialogue(*prev); + if (prev != Line.end()) previous = AssEntry::GetAsDialogue(*prev); else previous = NULL; // Strip ASS tags @@ -522,7 +523,7 @@ void AssFile::DialogueToSRT(AssDialogue *current,std::list::iterator void AssFile::ConvertToSRT () { using std::list; list::iterator next; - list::iterator prev = NULL; + list::iterator prev = Line.end(); // Sort lines Line.sort(LessByPointedToValue()); @@ -702,7 +703,7 @@ void AssFile::InsertStyle (AssStyle *style) { // Variables using std::list; AssEntry *curEntry; - list::iterator lastStyle = NULL; + list::iterator lastStyle = Line.end(); list::iterator cur; int lasttime; wxString lastGroup; @@ -718,7 +719,7 @@ void AssFile::InsertStyle (AssStyle *style) { } // No styles found, add them - if (lastStyle == NULL) { + if (lastStyle == Line.end()) { // Add space curEntry = new AssEntry(_T("")); curEntry->group = lastGroup; diff --git a/core/dialog_search_replace.cpp b/core/dialog_search_replace.cpp index 40b7e1978..2e4cc3461 100644 --- a/core/dialog_search_replace.cpp +++ b/core/dialog_search_replace.cpp @@ -36,6 +36,7 @@ /////////// // Headers +#include #include #include "dialog_search_replace.h" #include "ass_file.h" diff --git a/core/dialog_selection.cpp b/core/dialog_selection.cpp index 9eb8e36b2..b680fcb73 100644 --- a/core/dialog_selection.cpp +++ b/core/dialog_selection.cpp @@ -36,6 +36,7 @@ /////////// // Headers +#include #include #include "dialog_selection.h" #include "subs_grid.h" diff --git a/core/main.cpp b/core/main.cpp index 0752b614b..3d4e54b5e 100644 --- a/core/main.cpp +++ b/core/main.cpp @@ -34,6 +34,13 @@ // +//////////////////////////// +// Enable XP-style controls +//#if defined(__WXMSW__) && !defined(__WXWINCE__) +//#pragma comment(linker, "\"/manifestdependency:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='X86' publicKeyToken='6595b64144ccf1df'\"") +//#endif + + //////////// // Includes #include