Diffusion KWin 3c4619893c0d

Don't update decoration when ServerSideDecoration gets destroyed and…

Authored by graesslin on May 19 2016, 2:37 PM.

Description

Don't update decoration when ServerSideDecoration gets destroyed and ShellClient is unmapped

Summary:
Most likely the window is in the process of getting destroyed. In that
case the following destroy of the Surface is also going to destroy the
decoration.

This was causing an interesting effect with the QQuickRenderControl used
by Aurorae. When getting destroyed it ensures that all posted events get
processed. This includes the destroy of the Surface which entered
ShellClient::destroyClient which again destroyed the decoration. In other
words a recursive destroy which ended with wonderful crashers due to
double deletions.

If the window is not unmapped this might still cause problems: more
testing needed.

Reviewers: Plasma

Subscribers: plasma-devel

Tags: Plasma

Differential Revision: https://phabricator.kde.org/D1641