Correctly check forcebackgroundcontrastrule
ClosedPublic

Authored by davidedmundson on Jun 11 2018, 9:44 AM.

Details

Summary

WindowBackgroundContrastRole property is a bool or undefined.

QVariant::isValid() returns true for QVariant(false) which is not what
we want for this code.

toBool on an invalid QVariant will return false.

Test Plan

NA. Was based on code review.
To get a bug you'd have to PresentWindows/Slide effect manipulate a sliding popup, which
AFAIK doesn't happen.

Diff Detail

Repository
R108 KWin
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
davidedmundson created this revision.Jun 11 2018, 9:44 AM
Restricted Application added a project: KWin. · View Herald TranscriptJun 11 2018, 9:44 AM
Restricted Application added a subscriber: kwin. · View Herald Transcript
davidedmundson requested review of this revision.Jun 11 2018, 9:44 AM
mart accepted this revision.Jun 11 2018, 9:52 AM
This revision is now accepted and ready to land.Jun 11 2018, 9:52 AM
zzag added a subscriber: zzag.Jun 11 2018, 10:15 AM

Nice! :-)

This revision was automatically updated to reflect the committed changes.