Commit ea7bcf35 authored by Méven Car's avatar Méven Car Committed by Méven Car
Browse files

Ensure to emit ResolutionRole dataChanged signals

BUG: 448855
parent 8bd4c098
Pipeline #131912 passed with stage
in 2 minutes and 34 seconds
......@@ -294,7 +294,7 @@ void OutputModel::add(const KScreen::OutputPtr &output)
endInsertRows();
connect(output.data(), &KScreen::Output::modesChanged, this, [this, output]() {
rolesChanged(output->id(), {ResolutionsRole, ResolutionIndexRole, SizeRole});
rolesChanged(output->id(), {ResolutionsRole, ResolutionIndexRole, ResolutionRole, SizeRole});
Q_EMIT sizeChanged();
});
......@@ -417,7 +417,7 @@ bool OutputModel::setResolution(int outputIndex, int resIndex)
QModelIndex index = createIndex(outputIndex, 0);
// Calling this directly ignores possible optimization when the
// refresh rate hasn't changed in fact. But that's ok.
Q_EMIT dataChanged(index, index, {ResolutionIndexRole, SizeRole, RefreshRateIndexRole});
Q_EMIT dataChanged(index, index, {ResolutionIndexRole, ResolutionRole, SizeRole, RefreshRateIndexRole});
Q_EMIT sizeChanged();
return true;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment