Use correct flag when checking whether a scene window is opaque
ClosedPublic

Authored by zzag on Jan 13 2019, 9:37 PM.

Details

Summary

Given that allclips contains opaque regions of higher windows, we should
check PAINT_WINDOW_TRANSLUCENT flag instead of PAINT_WINDOW_TRANSFORMED.

ba39d1f917c61aff02e84088fc3f3091f0eb977e introduced that check. Neither
the commit message nor the associated review have any comments regarding
checking PAINT_WINDOW_TRANSFORMED, so given the following comment

// Here we rely on WindowPrePaintData::setTranslucent() to remove
// the clip if needed.

PAINT_WINDOW_TRANSFORMED is most likely a typo.

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.
zzag created this revision.Jan 13 2019, 9:37 PM
Restricted Application added a project: KWin. · View Herald TranscriptJan 13 2019, 9:37 PM
Restricted Application added a subscriber: kwin. · View Herald Transcript
zzag requested review of this revision.Jan 13 2019, 9:37 PM
zzag added a comment.Jan 13 2019, 9:43 PM

I'm still not sure whether it's intentional or just a typo.

zzag added a comment.EditedJan 13 2019, 9:52 PM

Also, the review message mentions "individual commits":

For the individual commmits please see here:
http://quickgit.kde.org/index.php?p=clones%2Fkde-workspace%2Fknechtges%2Fpersonal.git&a=shortlog&h=refs/heads/optimizingPaintScreen

which is now https://cgit.kde.org/clones/kde-workspace/knechtges/personal.git/log/?h=optimizingPaintScreen. It looks like none of the commits has explanation why the TRANSFORMED flag is checked.

zzag added a comment.Jan 31 2019, 9:40 PM

If there are no objections, I'm going to land this revision.

zzag retitled this revision from Fix potential typo to Use correct flag when checking whether a toplevel is opaque.Jan 31 2019, 10:05 PM
zzag retitled this revision from Use correct flag when checking whether a toplevel is opaque to Use correct flag when checking whether a scene window is opaque.
graesslin accepted this revision.Feb 10 2019, 3:53 PM
graesslin added a subscriber: graesslin.

go for it, we have now enough time to notice any regressions till the next release.

This revision is now accepted and ready to land.Feb 10 2019, 3:53 PM
This revision was automatically updated to reflect the committed changes.