Windows: Repaint when switching off layered windows by opacity.

Task-number: QTBUG-29010

Change-Id: I565a800e5a5b4870bd3ee2e3fb3f55523334425f
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
This commit is contained in:
Friedemann Kleint 2013-03-01 13:37:51 +01:00 committed by The Qt Project
parent c0c38912eb
commit bc741b867c

View File

@ -257,6 +257,8 @@ static void setWindowOpacity(HWND hwnd, Qt::WindowFlags flags, bool hasAlpha, qr
} else {
QWindowsContext::user32dll.setLayeredWindowAttributes(hwnd, 0, (int)(level * 255), LWA_ALPHA);
}
} else if (IsWindowVisible(hwnd)) { // Repaint when switching from layered.
InvalidateRect(hwnd, NULL, TRUE);
}
#endif // !Q_OS_WINCE
}