Skip to content

Commit

Permalink
fix Duplicates smart bin incorrect after Not In Timeline
Browse files Browse the repository at this point in the history
  • Loading branch information
ddennedy committed Jan 4, 2025
1 parent f01893e commit d7cebcc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/docks/playlistdock.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,7 @@ class PlaylistProxyModel : public QSortFilterProxyModel
}
std::sort(hashes.begin(), hashes.end());
std::set<std::string> unique(hashes.begin(), hashes.end());
m_hashes.clear();
std::set_difference(hashes.begin(), hashes.end(), unique.begin(), unique.end(),
std::back_inserter(m_hashes));
LOG_INFO() << "Duplicates smart bin found" << m_hashes.size() << "items";
Expand Down Expand Up @@ -1147,9 +1148,9 @@ void PlaylistDock::setupActions()
icon = QIcon::fromTheme("folder-new",
QIcon(":/icons/oxygen/32x32/actions/folder-new.png"));
action->setIcon(icon);
action->setDisabled(true);
Actions.add("playlistNewBin", action, windowTitle());
connect(action, &QAction::triggered, this, [ = ]() {
ui->treeWidget->setVisible(true);
QInputDialog dialog(this);
dialog.setInputMode(QInputDialog::TextInput);
dialog.setWindowTitle(action->text());
Expand All @@ -1171,7 +1172,6 @@ void PlaylistDock::setupActions()
action->setCheckable(true);
connect(action, &QAction::triggered, this, [ = ](bool checked) {
ui->treeWidget->setVisible(checked);
Actions["playlistNewBin"]->setEnabled(checked);
});
Actions.add("playlistBinView", action, windowTitle());

Expand Down

0 comments on commit d7cebcc

Please sign in to comment.