Skip to content

Commit

Permalink
Fix a C++17 warning
Browse files Browse the repository at this point in the history
  • Loading branch information
Jojo-Schmitz committed Oct 3, 2020
1 parent 1d3d029 commit 054ac33
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mu4/palette/internal/palette/palette.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ Palette::Palette(std::unique_ptr<PalettePanel> pp, QWidget* parent)

const auto allCells = pp->takeCells(0, pp->ncells());
for (const PaletteCellPtr& cell : allCells) {
Element* e = cell.unique() ? cell->element.release() : (cell->element ? cell->element->clone() : nullptr);
Element* e = (cell.use_count() == 1) ? cell->element.release() : (cell->element ? cell->element->clone() : nullptr);
if (e) {
PaletteCell* newCell = append(e, cell->name, cell->tag, cell->mag);
newCell->drawStaff = cell->drawStaff;
Expand Down

0 comments on commit 054ac33

Please sign in to comment.