Delete AssDialogue::StripTag

It is not actually used anywhere.
This commit is contained in:
Thomas Goyne 2012-12-10 17:43:29 -08:00
parent 8c2062f0c7
commit 534f574a87
2 changed files with 0 additions and 27 deletions

View file

@ -260,31 +260,6 @@ void AssDialogue::StripTags() {
Text = GetStrippedText();
}
void AssDialogue::StripTag(wxString const& tag_name) {
boost::ptr_vector<AssDialogueBlock> blocks(ParseTags());
wxString new_text;
// Look for blocks
for (auto& block : blocks) {
if (block.GetType() != BLOCK_OVERRIDE) {
new_text += block.GetText();
continue;
}
AssDialogueBlockOverride *over = static_cast<AssDialogueBlockOverride*>(&block);
wxString temp;
for (auto const& tag : over->Tags) {
if (tag.Name != tag_name)
temp += tag;
}
if (!temp.empty())
new_text += "{" + temp + "}";
}
Text = new_text;
}
static wxString get_text(AssDialogueBlock &d) { return d.GetText(); }
void AssDialogue::UpdateText(boost::ptr_vector<AssDialogueBlock>& blocks) {
if (blocks.empty()) return;

View file

@ -156,8 +156,6 @@ public:
/// Strip all ASS tags from the text
void StripTags();
/// Strip a specific ASS tag from the text
/// @param tag_name Tag to strip, with leading slash
void StripTag(wxString const& tag_name);
/// Get text without tags
wxString GetStrippedText() const;