QML: rendering problems after minimizing frameless window



I’m trying to implement the QML-based UI inside of frameless (Qt::FramelessWindowHint) window.
But QML engine stops responding to mouse clicks after window is minimized via showMinimized() method.

the code follows:

Image {
source: “minimize.png”
scale: mouse.pressed ? 0.8 : 1.0
smooth: mouse.pressed

MouseArea {
    id: mouse
    anchors.fill: parent
    anchors.margins: -5
    onClicked: {
        console.log("MinimizeButton clicked");
        viewer.showMinimized(); // If comment out this line, works fine


After clicking on MouseArea window is minimized as needed. But all Qt Quick controls inside window become frozen after window has been restored.
Windows without Qt::FramelessWindowHint flag are not affected.
showMinimized() is not the only method to reproduce, “Show Desktop” command of OS gives the same effect. OS is Windows XP.

Is there any workaround for this problem?



obsessed, we also experienced this problem in one of our projects.
This bug is reported [bugreports.qt.nokia.com] but is not solved yet. Following the link to the bug report, you’ll find this workaround:
void MainWindow::showEvent(QShowEvent *event)
QApplication::postEvent(this, new QEvent(QEvent::UpdateRequest), Qt::LowEventPriority);