diff options
Diffstat (limited to 'src/widgets')
-rw-r--r-- | src/widgets/accessible/qaccessiblewidget.cpp | 19 | ||||
-rw-r--r-- | src/widgets/dialogs/qwizard_win.cpp | 16 | ||||
-rw-r--r-- | src/widgets/util/qsystemtrayicon_win.cpp | 2 |
3 files changed, 11 insertions, 26 deletions
diff --git a/src/widgets/accessible/qaccessiblewidget.cpp b/src/widgets/accessible/qaccessiblewidget.cpp index 17ba14de39..bf3c187d62 100644 --- a/src/widgets/accessible/qaccessiblewidget.cpp +++ b/src/widgets/accessible/qaccessiblewidget.cpp @@ -377,25 +377,6 @@ QAccessibleWidget::relations(QAccessible::Relation match /*= QAccessible::AllRel } } - if (match & QAccessible::Controller) { - const QAccessible::Relation rel = QAccessible::Controller; - QACConnectionObject *connectionObject = (QACConnectionObject*)object(); - const QObjectList senderList = connectionObject->senderList(); - for (int s = 0; s < senderList.count(); ++s) { - QObject *sender = senderList.at(s); - if (sender->isWidgetType() && sender != object()) { - QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(sender); - QACConnectionObject *connectionSender = (QACConnectionObject*)sender; - QStringList senderPrimarySignals = static_cast<QAccessibleWidget*>(iface)->d->primarySignals; - for (int sig = 0; sig < senderPrimarySignals.count(); ++sig) { - const QByteArray strSignal = senderPrimarySignals.at(sig).toLatin1(); - if (connectionSender->isSender(object(), strSignal.constData())) - rels.append(qMakePair(iface, rel)); - } - } - } - } - if (match & QAccessible::Controlled) { QObjectList allReceivers; QACConnectionObject *connectionObject = (QACConnectionObject*)object(); diff --git a/src/widgets/dialogs/qwizard_win.cpp b/src/widgets/dialogs/qwizard_win.cpp index 6359ebfb09..4a4f109a82 100644 --- a/src/widgets/dialogs/qwizard_win.cpp +++ b/src/widgets/dialogs/qwizard_win.cpp @@ -306,7 +306,7 @@ bool QVistaHelper::setDWMTitleBar(TitleBarChangeType type) { bool value = false; if (vistaState() == VistaAero) { - WIZ_MARGINS mar = {0}; + WIZ_MARGINS mar = {0, 0, 0, 0}; if (type == NormalTitleBar) mar.cyTopHeight = 0; else @@ -639,13 +639,14 @@ bool QVistaHelper::eventFilter(QObject *obj, QEvent *event) HFONT QVistaHelper::getCaptionFont(HANDLE hTheme) { - LOGFONT lf = {0}; + LOGFONT lf = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, { 0 } }; if (!hTheme) pGetThemeSysFont(hTheme, WIZ_TMT_CAPTIONFONT, &lf); else { - NONCLIENTMETRICS ncm = {sizeof(NONCLIENTMETRICS)}; + NONCLIENTMETRICS ncm; + ncm.cbSize = sizeof(NONCLIENTMETRICS); SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(NONCLIENTMETRICS), &ncm, false); lf = ncm.lfMessageFont; } @@ -662,7 +663,8 @@ bool QVistaHelper::drawTitleText(QPainter *painter, const QString &text, const Q // Set up a memory DC and bitmap that we'll draw into HDC dcMem; HBITMAP bmp; - BITMAPINFO dib = {{0}}; + BITMAPINFO dib; + ZeroMemory(&dib, sizeof(dib)); dcMem = CreateCompatibleDC(hdc); dib.bmiHeader.biSize = sizeof(BITMAPINFOHEADER); @@ -680,7 +682,8 @@ bool QVistaHelper::drawTitleText(QPainter *painter, const QString &text, const Q HFONT hOldFont = (HFONT)SelectObject(dcMem, (HGDIOBJ) hCaptionFont); // Draw the text! - WIZ_DTTOPTS dto = { sizeof(WIZ_DTTOPTS) }; + WIZ_DTTOPTS dto; + dto.dwSize = sizeof(WIZ_DTTOPTS); const UINT uFormat = WIZ_DT_SINGLELINE|WIZ_DT_CENTER|WIZ_DT_VCENTER|WIZ_DT_NOPREFIX; RECT rctext ={0,0, rect.width(), rect.height()}; @@ -708,7 +711,8 @@ bool QVistaHelper::drawBlackRect(const QRect &rect, HDC hdc) // Set up a memory DC and bitmap that we'll draw into HDC dcMem; HBITMAP bmp; - BITMAPINFO dib = {{0}}; + BITMAPINFO dib; + ZeroMemory(&dib, sizeof(dib)); dcMem = CreateCompatibleDC(hdc); dib.bmiHeader.biSize = sizeof(BITMAPINFOHEADER); diff --git a/src/widgets/util/qsystemtrayicon_win.cpp b/src/widgets/util/qsystemtrayicon_win.cpp index 731b547e2a..e81a8eee93 100644 --- a/src/widgets/util/qsystemtrayicon_win.cpp +++ b/src/widgets/util/qsystemtrayicon_win.cpp @@ -466,7 +466,7 @@ QRect QSystemTrayIconSys::findIconGeometry(const int iconId) if (currentIconHandle == m_hwnd && currentIconId == iconId && !isHidden) { SendMessage(trayHandle, TB_GETITEMRECT, toolbarButton , (LPARAM)data); - RECT iconRect = {0, 0}; + RECT iconRect = {0, 0, 0, 0}; if(ReadProcessMemory(trayProcess, data, &iconRect, sizeof(RECT), &numBytes)) { MapWindowPoints(trayHandle, NULL, (LPPOINT)&iconRect, 2); QRect geometry(iconRect.left + 1, iconRect.top + 1, |