From 9a53dc0440350236e19cdfe6e6f9f093b5a9a070 Mon Sep 17 00:00:00 2001 From: Thomas Goyne Date: Sat, 19 Nov 2011 04:46:45 +0000 Subject: [PATCH] Eliminate some unused variables Originally committed to SVN as r5893. --- aegisub/src/audio_player_openal.cpp | 1 - aegisub/src/charset_detect.cpp | 6 +----- aegisub/src/subs_grid.cpp | 4 +--- 3 files changed, 2 insertions(+), 9 deletions(-) diff --git a/aegisub/src/audio_player_openal.cpp b/aegisub/src/audio_player_openal.cpp index 183ed66ff..53c5a11f3 100644 --- a/aegisub/src/audio_player_openal.cpp +++ b/aegisub/src/audio_player_openal.cpp @@ -187,7 +187,6 @@ void OpenALPlayer::Stop(bool timerToo) void OpenALPlayer::FillBuffers(ALsizei count) { // Do the actual filling/queueing - ALuint bufid = buf_first_free; for (count = mid(1, count, buffers_free); count > 0; --count) { ALsizei fill_len = mid(0, decode_buffer.size() / bpf, end_frame - cur_frame); diff --git a/aegisub/src/charset_detect.cpp b/aegisub/src/charset_detect.cpp index 423554f5b..8c3284e45 100644 --- a/aegisub/src/charset_detect.cpp +++ b/aegisub/src/charset_detect.cpp @@ -54,20 +54,16 @@ namespace CharSetDetect { wxString GetEncoding(wxString const& filename) { - bool unknown = 0; - agi::charset::CharsetListDetected list; agi::charset::CharsetListDetected::const_iterator i_lst; try { agi::charset::DetectAll(STD_STR(filename), list); } catch (const agi::charset::UnknownCharset&) { - unknown = 1; + /// @todo If the charset is unknown we need to display a complete list of character sets. } - /// @todo If the charset is unknown we need to display a complete list of character sets. if (list.size() > 1) { - // Get choice from user wxArrayString choices; diff --git a/aegisub/src/subs_grid.cpp b/aegisub/src/subs_grid.cpp index 871403cf0..6ab4c0d62 100644 --- a/aegisub/src/subs_grid.cpp +++ b/aegisub/src/subs_grid.cpp @@ -167,7 +167,7 @@ void SubtitlesGrid::InsertLine(AssDialogue *line,int n,bool after,bool update) { entryIter pos = std::find(context->ass->Line.begin(), context->ass->Line.end(), rel_line); if (after) ++pos; - entryIter newIter = context->ass->Line.insert(pos,line); + context->ass->Line.insert(pos,line); // Update if (update) { @@ -305,7 +305,6 @@ void SubtitlesGrid::PasteLines(int n,bool pasteOver) { void SubtitlesGrid::DeleteLines(wxArrayInt target, bool flagModified) { entryIter before_first = std::find_if(context->ass->Line.begin(), context->ass->Line.end(), cast()); --before_first; - int old_active_line_index = GetDialogueIndex(GetActiveLine()); int row = -1; int deleted = 0; @@ -325,7 +324,6 @@ void SubtitlesGrid::DeleteLines(wxArrayInt target, bool flagModified) { AssDialogue *def = new AssDialogue; ++before_first; context->ass->Line.insert(before_first, def); - old_active_line_index = 0; } if (flagModified) {