catch NULL client pointer
BUG: 320589 FIXED-IN: 4.11 REVIEW: 110782
This commit is contained in:
parent
3a3579d6d4
commit
6f5f999c54
1 changed files with 10 additions and 5 deletions
15
scene.cpp
15
scene.cpp
|
@ -748,15 +748,20 @@ WindowQuadList Scene::Window::buildQuads(bool force) const
|
||||||
ret = makeQuads(WindowQuadContents, contents);
|
ret = makeQuads(WindowQuadContents, contents);
|
||||||
|
|
||||||
QRect rects[4];
|
QRect rects[4];
|
||||||
client->layoutDecorationRects(rects[0], rects[1], rects[2], rects[3], Client::WindowRelative);
|
bool isShadedClient = false;
|
||||||
|
|
||||||
if (!client || !(center.isEmpty() || client->isShade()))
|
if (client) {
|
||||||
ret += makeDecorationQuads(rects, decoration);
|
client->layoutDecorationRects(rects[0], rects[1], rects[2], rects[3], Client::WindowRelative);
|
||||||
else {
|
isShadedClient = client->isShade() || center.isEmpty();
|
||||||
// this is a shaded client, we have to create four decoration quads
|
}
|
||||||
|
|
||||||
|
if (isShadedClient) {
|
||||||
const QRect bounding = rects[0] | rects[1] | rects[2] | rects[3];
|
const QRect bounding = rects[0] | rects[1] | rects[2] | rects[3];
|
||||||
ret += makeDecorationQuads(rects, bounding);
|
ret += makeDecorationQuads(rects, bounding);
|
||||||
|
} else {
|
||||||
|
ret += makeDecorationQuads(rects, decoration);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if (m_shadow) {
|
if (m_shadow) {
|
||||||
ret << m_shadow->shadowQuads();
|
ret << m_shadow->shadowQuads();
|
||||||
|
|
Loading…
Reference in a new issue