been_1990
16th June 2010, 00:32
I have a widget with these flags and attributes:
setWindowFlags(Qt::SubWindow | Qt::FramelessWindowHint );
setTransformationAnchor(QGraphicsView::AnchorViewC enter);
this->setAttribute(Qt::WA_TranslucentBackground);
this->setAttribute(Qt::WA_TransparentForMouseEvents);
To make the window always on top:
setWindowFlags(Qt::FramelessWindowHint | Qt::SubWindow | Qt::WindowStaysOnTopHint);
So when the app runs, the window is on top of every other window, but as soon as I click any other window it goes behind the windowI clicked.
Why this behaviour?
setWindowFlags(Qt::SubWindow | Qt::FramelessWindowHint );
setTransformationAnchor(QGraphicsView::AnchorViewC enter);
this->setAttribute(Qt::WA_TranslucentBackground);
this->setAttribute(Qt::WA_TransparentForMouseEvents);
To make the window always on top:
setWindowFlags(Qt::FramelessWindowHint | Qt::SubWindow | Qt::WindowStaysOnTopHint);
So when the app runs, the window is on top of every other window, but as soon as I click any other window it goes behind the windowI clicked.
Why this behaviour?