summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPrasanth Ullattil <prasanth.ullattil@nokia.com>2010-02-26 09:54:41 (GMT)
committerPrasanth Ullattil <prasanth.ullattil@nokia.com>2010-02-26 10:30:49 (GMT)
commitc027f0ae1967ec1d64cb2c9679c8b57f18faf7f5 (patch)
treec27aecad898056bf207caddc9c054bfe7529a60c /src
parentac6c9dc0ee0ce53c0aca479f794902e8062a0a4b (diff)
downloadQt-c027f0ae1967ec1d64cb2c9679c8b57f18faf7f5.zip
Qt-c027f0ae1967ec1d64cb2c9679c8b57f18faf7f5.tar.gz
Qt-c027f0ae1967ec1d64cb2c9679c8b57f18faf7f5.tar.bz2
ActiveQt Internet Explorer component causes Desktop Icons to flicker.
This happens only if IE is embedded in an frameless window. The repaint caused by calling EnableModeless() is making the desktop icons flicker. This repaint generated via ActiveQt will be ignored by QtGui. This is done by checking if the window style is already in the required state or not. Task-number: QTBUG-8355 Reviewed-by: Denis
Diffstat (limited to 'src')
-rw-r--r--src/gui/kernel/qwidget.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/gui/kernel/qwidget.cpp b/src/gui/kernel/qwidget.cpp
index 850e961..91a11ec 100644
--- a/src/gui/kernel/qwidget.cpp
+++ b/src/gui/kernel/qwidget.cpp
@@ -7925,13 +7925,16 @@ inline void setDisabledStyle(QWidget *w, bool setStyle)
// set/reset WS_DISABLED style.
if(w && w->isWindow() && w->isVisible() && w->isEnabled()) {
LONG dwStyle = GetWindowLong(w->winId(), GWL_STYLE);
+ LONG newStyle = dwStyle;
if (setStyle)
- dwStyle |= WS_DISABLED;
+ newStyle |= WS_DISABLED;
else
- dwStyle &= ~WS_DISABLED;
- SetWindowLong(w->winId(), GWL_STYLE, dwStyle);
- // we might need to repaint in some situations (eg. menu)
- w->repaint();
+ newStyle &= ~WS_DISABLED;
+ if (newStyle != dwStyle) {
+ SetWindowLong(w->winId(), GWL_STYLE, newStyle);
+ // we might need to repaint in some situations (eg. menu)
+ w->repaint();
+ }
}
}
#endif