From 3aa7424998de98512cfae512f3b17bb4339fcb07 Mon Sep 17 00:00:00 2001 From: Amar Takhar Date: Wed, 2 Sep 2009 08:48:07 +0000 Subject: [PATCH] Sprinkle const to remove warnings, add {} behind a while loop. Originally committed to SVN as r3464. --- aegisub/src/subtitle_format_transtation.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/aegisub/src/subtitle_format_transtation.cpp b/aegisub/src/subtitle_format_transtation.cpp index e8bf8d4aa..173977795 100644 --- a/aegisub/src/subtitle_format_transtation.cpp +++ b/aegisub/src/subtitle_format_transtation.cpp @@ -135,8 +135,8 @@ wxString TranStationSubtitleFormat::ConvertLine(AssDialogue *current, FPSRationa // Get line data AssStyle *style = GetAssFile()->GetStyle(current->Style); int valign = 0; - wxChar *halign = _T(" "); // default is centered - wxChar *type = _T("N"); // no special style + const wxChar *halign = _T(" "); // default is centered + const wxChar *type = _T("N"); // no special style if (style) { if (style->alignment >= 4) valign = 4; if (style->alignment >= 7) valign = 9; @@ -168,7 +168,7 @@ wxString TranStationSubtitleFormat::ConvertLine(AssDialogue *current, FPSRationa current->Text.Replace(_T("\\h"),_T(" "),true); current->Text.Replace(_T("\\n"),lineEnd,true); current->Text.Replace(_T("\\N"),lineEnd,true); - while (current->Text.Replace(lineEnd+lineEnd,lineEnd,true)); + while (current->Text.Replace(lineEnd+lineEnd,lineEnd,true)) {}; return header + current->Text; }