diff --git a/src/audio_timing_dialogue.cpp b/src/audio_timing_dialogue.cpp index 3b53c8010..2b11fb1ac 100644 --- a/src/audio_timing_dialogue.cpp +++ b/src/audio_timing_dialogue.cpp @@ -754,8 +754,7 @@ void AudioTimingControllerDialogue::RegenerateInactiveLines() if (mode == 2) { - entryIter next = - find_if(++current_line, context->ass->Line.end(), predicate); + entryIter next = std::find_if(++current_line, context->ass->Line.end(), predicate); if (next != context->ass->Line.end()) AddInactiveLine(sel, static_cast(&*next)); } diff --git a/src/auto4_lua.cpp b/src/auto4_lua.cpp index eb55c1539..663abf5e9 100644 --- a/src/auto4_lua.cpp +++ b/src/auto4_lua.cpp @@ -931,7 +931,7 @@ namespace Automation4 { throw LuaForEachBreak(); } - advance(it, cur - last_idx); + std::advance(it, cur - last_idx); AssDialogue *diag = dynamic_cast(&*it); if (!diag) { diff --git a/src/command/edit.cpp b/src/command/edit.cpp index 8f974a640..a0f5a5239 100644 --- a/src/command/edit.cpp +++ b/src/command/edit.cpp @@ -843,7 +843,7 @@ struct edit_line_paste_over : public Command { AssDialogue *ret = paste_over(c->parent, pasteOverOptions, new_line, static_cast(&*pos)); if (ret) - pos = find_if(next(pos), c->ass->Line.end(), cast()); + pos = std::find_if(std::next(pos), c->ass->Line.end(), cast()); return ret; }); } diff --git a/src/dialog_timing_processor.cpp b/src/dialog_timing_processor.cpp index a9c4e8042..3e4071758 100644 --- a/src/dialog_timing_processor.cpp +++ b/src/dialog_timing_processor.cpp @@ -314,7 +314,7 @@ std::vector DialogTimingProcessor::SortDialogues() { // Check if rows are valid for (auto diag : sorted) { if (diag->Start > diag->End) { - int line = count_if(c->ass->Line.begin(), c->ass->Line.iterator_to(*diag), cast()); + int line = std::count_if(c->ass->Line.begin(), c->ass->Line.iterator_to(*diag), cast()); wxMessageBox( wxString::Format(_("One of the lines in the file (%i) has negative duration. Aborting."), line), _("Invalid script"), diff --git a/src/dialog_translation.cpp b/src/dialog_translation.cpp index 60a70357c..9fd4ca176 100644 --- a/src/dialog_translation.cpp +++ b/src/dialog_translation.cpp @@ -66,8 +66,8 @@ DialogTranslation::DialogTranslation(agi::Context *c) , file_change_connection(c->ass->AddCommitListener(&DialogTranslation::OnExternalCommit, this)) , active_line_connection(c->selectionController->AddActiveLineListener(&DialogTranslation::OnActiveLineChanged, this)) , active_line(c->selectionController->GetActiveLine()) -, line_count(count_if(c->ass->Line.begin(), c->ass->Line.end(), cast())) -, line_number(count_if(c->ass->Line.begin(), c->ass->Line.iterator_to(*active_line), cast()) + 1) +, line_count(std::count_if(c->ass->Line.begin(), c->ass->Line.end(), cast())) +, line_number(std::count_if(c->ass->Line.begin(), c->ass->Line.iterator_to(*active_line), cast()) + 1) { SetIcon(GETICON(translation_toolbutton_16)); @@ -175,7 +175,7 @@ void DialogTranslation::OnActiveLineChanged(AssDialogue *new_line) { active_line = new_line; blocks = active_line->ParseTags(); cur_block = 0; - line_number = count_if(c->ass->Line.begin(), c->ass->Line.iterator_to(*new_line), cast()) + 1; + line_number = std::count_if(c->ass->Line.begin(), c->ass->Line.iterator_to(*new_line), cast()) + 1; if (bad_block(blocks[cur_block]) && !NextBlock()) { wxMessageBox(_("No more lines to translate.")); @@ -185,7 +185,7 @@ void DialogTranslation::OnActiveLineChanged(AssDialogue *new_line) { void DialogTranslation::OnExternalCommit(int commit_type) { if (commit_type == AssFile::COMMIT_NEW || commit_type & AssFile::COMMIT_DIAG_ADDREM) { - line_count = count_if(c->ass->Line.begin(), c->ass->Line.end(), cast()); + line_count = std::count_if(c->ass->Line.begin(), c->ass->Line.end(), cast()); line_number_display->SetLabel(wxString::Format(_("Current line: %d/%d"), (int)line_number, (int)line_count)); } diff --git a/src/threaded_frame_source.cpp b/src/threaded_frame_source.cpp index 9cf073376..f855a963b 100644 --- a/src/threaded_frame_source.cpp +++ b/src/threaded_frame_source.cpp @@ -150,7 +150,7 @@ void ThreadedFrameSource::UpdateSubtitles(const AssFile *new_subs, std::setLine.begin(); for (auto& update : changed) { - advance(it, update.first - i); + std::advance(it, update.first - i); i = update.first; subs->Line.insert(it, *update.second); delete &*it--;