From 50aca3d0208ba88661b98a3607522f259c5530fd Mon Sep 17 00:00:00 2001 From: Stephen Kelly Date: Tue, 17 Apr 2012 18:12:06 +0200 Subject: Fix some unsigned comparison warnings. Change-Id: I4e72dbb6e207757c8bb75a7726c83ed5916df094 Reviewed-by: Richard J. Moore --- src/widgets/dialogs/qmessagebox.cpp | 2 +- src/widgets/kernel/qwidgetwindow_qpa.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/widgets') diff --git a/src/widgets/dialogs/qmessagebox.cpp b/src/widgets/dialogs/qmessagebox.cpp index ea33dc8d0b..92915b1bb1 100644 --- a/src/widgets/dialogs/qmessagebox.cpp +++ b/src/widgets/dialogs/qmessagebox.cpp @@ -1371,7 +1371,7 @@ void QMessageBox::keyPressEvent(QKeyEvent *e) for (int i = 0; i < buttons.count(); ++i) { QAbstractButton *pb = buttons.at(i); QKeySequence shortcut = pb->shortcut(); - if (!shortcut.isEmpty() && key == (shortcut[0] & ~Qt::MODIFIER_MASK)) { + if (!shortcut.isEmpty() && key == int(shortcut[0] & ~Qt::MODIFIER_MASK)) { pb->animateClick(); return; } diff --git a/src/widgets/kernel/qwidgetwindow_qpa.cpp b/src/widgets/kernel/qwidgetwindow_qpa.cpp index d124ec768a..0a45cce62e 100644 --- a/src/widgets/kernel/qwidgetwindow_qpa.cpp +++ b/src/widgets/kernel/qwidgetwindow_qpa.cpp @@ -478,7 +478,7 @@ void QWidgetWindow::handleWindowStateChangedEvent(QWindowStateChangeEvent *event // Sent event if the state changed (that is, it is not triggered by // QWidget::setWindowState(), which also sends an event to the widget). - if (widgetState != m_widget->data->window_state) { + if (widgetState != int(m_widget->data->window_state)) { m_widget->data->window_state = widgetState; QWindowStateChangeEvent widgetEvent(eventState); QGuiApplication::sendSpontaneousEvent(m_widget, &widgetEvent); -- cgit v1.2.3