mirror of
https://github.com/strawberrymusicplayer/strawberry
synced 2025-02-02 10:36:45 +01:00
Simplify return
This commit is contained in:
parent
e5c85ddd32
commit
6d8b0b3ab6
@ -534,9 +534,7 @@ void MergedProxyModel::LayoutChanged() {
|
||||
|
||||
bool MergedProxyModel::IsKnownModel(const QAbstractItemModel *model) const {
|
||||
|
||||
if (model == this || model == sourceModel() || merge_points_.contains(const_cast<QAbstractItemModel*>(model)))
|
||||
return true;
|
||||
return false;
|
||||
return (model == this || model == sourceModel() || merge_points_.contains(const_cast<QAbstractItemModel*>(model)));
|
||||
|
||||
}
|
||||
|
||||
|
@ -515,11 +515,7 @@ bool EditTagDialog::DoesValueVary(const QModelIndexList &sel, const QString &id)
|
||||
|
||||
bool EditTagDialog::IsValueModified(const QModelIndexList &sel, const QString &id) const {
|
||||
|
||||
if (std::any_of(sel.begin(), sel.end(), [this, id](const QModelIndex &i){ return data_[i.row()].original_value(id) != data_[i.row()].current_value(id); })) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
return std::any_of(sel.begin(), sel.end(), [this, id](const QModelIndex &i){ return data_[i.row()].original_value(id) != data_[i.row()].current_value(id); });
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user