Tag editor: only write files with modified tags (#536)

wilder
gardockt 2 years ago committed by GitHub
parent 8746ded880
commit 95bca25cb6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 3
      src/screens/tag_editor.cpp

@ -797,6 +797,8 @@ void TagEditor::runAction()
bool success = 1; bool success = 1;
Statusbar::print("Writing changes..."); Statusbar::print("Writing changes...");
for (auto it = EditedSongs.begin(); it != EditedSongs.end(); ++it) for (auto it = EditedSongs.begin(); it != EditedSongs.end(); ++it)
{
if ((*it)->isModified())
{ {
Statusbar::printf("Writing tags in \"%1%\"...", (*it)->getName()); Statusbar::printf("Writing tags in \"%1%\"...", (*it)->getName());
if (!Tags::write(**it)) if (!Tags::write(**it))
@ -807,6 +809,7 @@ void TagEditor::runAction()
break; break;
} }
} }
}
if (success) if (success)
{ {
Statusbar::print("Tags updated"); Statusbar::print("Tags updated");

Loading…
Cancel
Save