mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-26 14:23:09 +00:00
quicksettings/screenrotation: Nullptr check
Add nullptr check, since apparently it's possible for outputs to be given as nullptr.
This commit is contained in:
parent
c2731f650e
commit
a508c8d524
1 changed files with 4 additions and 0 deletions
|
|
@ -86,6 +86,10 @@ void ScreenRotationUtil::actuallySetAutoScreenRotationEnabled(bool value)
|
|||
|
||||
const auto outputs = m_config->outputs();
|
||||
for (KScreen::OutputPtr output : outputs) {
|
||||
if (!output) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (output->autoRotatePolicy() != policy) {
|
||||
output->setAutoRotatePolicy(policy);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue