From b55a0df8e115c8275ea3139e66d52fe954bb2049 Mon Sep 17 00:00:00 2001 From: Jonas Kvinge Date: Fri, 21 Jul 2023 07:15:42 +0200 Subject: [PATCH] CollectionView: Remove useless variable --- src/collection/collectionview.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/collection/collectionview.cpp b/src/collection/collectionview.cpp index 030600d3..5fd72e0d 100644 --- a/src/collection/collectionview.cpp +++ b/src/collection/collectionview.cpp @@ -404,7 +404,6 @@ void CollectionView::contextMenuEvent(QContextMenuEvent *e) { } const int songs_selected = regular_elements; - const bool regular_elements_only = songs_selected == regular_elements && regular_elements > 0; // in all modes action_load_->setEnabled(songs_selected > 0); @@ -432,8 +431,8 @@ void CollectionView::contextMenuEvent(QContextMenuEvent *e) { action_delete_files_->setVisible(false); #endif - action_show_in_various_->setVisible(regular_elements_only); - action_no_show_in_various_->setVisible(regular_elements_only); + action_show_in_various_->setVisible(songs_selected > 0); + action_no_show_in_various_->setVisible(songs_selected > 0); // only when all selected items are editable action_organize_->setEnabled(regular_elements == regular_editable);