Skip to content

scene: Fix DecorationItem reacting to new geometry

Vlad Zahorodnii requested to merge work/cherry-pick-857766eb into Plasma/6.0

Window::layoutDecorationRects() uses KDecoration2::Decoration::rect() to get the bounding decoration rect.

While Decoration::rect() should normally match Window::rect(), they can diverge for a brief moment during async geometry updates. The worst possible case is that the cached item quads may not be invalidated when the geometry updates saddle.

To fix that, make DecorationItem monitor decorated client size changes instead of window frame geometry changes. The reason for that is that Decoration::size() is effectively decorated client size with added border margins.

(cherry picked from commit 857766eb)

Merge request reports