make sure OSD doesn't have Dialog flag

an OSD can't be a Dialog, as qt xcb would attempt to set a
transient parent for it, same as panels, which in turn will
make for invisible osd on autohide panels

Change-Id: I5afea6d4bfa0bfee8b3453e78a1c214a3a0894ec
reviewed-by: Martin Graesslin <mgraesslin@kde.org>
CCMAIL:distributions@kde.org
BUG:370433
This commit is contained in:
Marco Martin 2016-11-02 11:56:40 +01:00
parent e14a60f9a4
commit 62b0865492

View File

@ -1037,6 +1037,11 @@ void Dialog::setType(WindowType type)
} else {
setFlags(Qt::FramelessWindowHint | flags());
}
//an OSD can't be a Dialog, as qt xcb would attempt to set a transient parent for it
//see bug 370433
if (type == OnScreenDisplay) {
setFlags((flags() & ~Qt::Dialog) | Qt::Window);
}
if (d->backgroundHints == Dialog::NoBackground) {
d->frameSvgItem->setImagePath(QString());