ugh. remove this pattern from list using std::list::remove instead of iteration
This commit is contained in:
@@ -458,9 +458,7 @@ void TagEditor::EnterPressed()
|
|||||||
}
|
}
|
||||||
else if (success)
|
else if (success)
|
||||||
{
|
{
|
||||||
for (std::list<std::string>::iterator it = Patterns.begin(); it != Patterns.end(); ++it)
|
Patterns.remove(Config.pattern);
|
||||||
if (*it == Config.pattern)
|
|
||||||
--(it = Patterns.erase(it));
|
|
||||||
Patterns.insert(Patterns.begin(), Config.pattern);
|
Patterns.insert(Patterns.begin(), Config.pattern);
|
||||||
quit = 1;
|
quit = 1;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user