diff options
Diffstat (limited to 'src/widgets/widgets')
-rw-r--r-- | src/widgets/widgets/qcalendarwidget.cpp | 17 | ||||
-rw-r--r-- | src/widgets/widgets/qcheckbox.cpp | 5 | ||||
-rw-r--r-- | src/widgets/widgets/qdatetimeedit.cpp | 18 | ||||
-rw-r--r-- | src/widgets/widgets/qdatetimeedit_p.h | 2 | ||||
-rw-r--r-- | src/widgets/widgets/qdialogbuttonbox.cpp | 58 | ||||
-rw-r--r-- | src/widgets/widgets/qdialogbuttonbox_p.h | 5 | ||||
-rw-r--r-- | src/widgets/widgets/qdockwidget.cpp | 56 | ||||
-rw-r--r-- | src/widgets/widgets/qdockwidget_p.h | 1 | ||||
-rw-r--r-- | src/widgets/widgets/qframe.cpp | 6 | ||||
-rw-r--r-- | src/widgets/widgets/qlineedit.cpp | 7 | ||||
-rw-r--r-- | src/widgets/widgets/qmainwindowlayout.cpp | 44 | ||||
-rw-r--r-- | src/widgets/widgets/qplaintextedit.cpp | 1 | ||||
-rw-r--r-- | src/widgets/widgets/qrubberband.cpp | 1 | ||||
-rw-r--r-- | src/widgets/widgets/qsplitter.cpp | 1 | ||||
-rw-r--r-- | src/widgets/widgets/qtextedit.cpp | 1 | ||||
-rw-r--r-- | src/widgets/widgets/qtoolbar.cpp | 1 | ||||
-rw-r--r-- | src/widgets/widgets/qtoolbar_p.h | 1 | ||||
-rw-r--r-- | src/widgets/widgets/qwidgettextcontrol.cpp | 1 |
18 files changed, 173 insertions, 53 deletions
diff --git a/src/widgets/widgets/qcalendarwidget.cpp b/src/widgets/widgets/qcalendarwidget.cpp index 034127b4f3..0495b20422 100644 --- a/src/widgets/widgets/qcalendarwidget.cpp +++ b/src/widgets/widgets/qcalendarwidget.cpp @@ -2731,12 +2731,29 @@ bool QCalendarWidget::isGridVisible() const return d->m_view->showGrid(); } +/*! + \since 5.14 + Report the calendar system in use by this widget. + + \sa setCalendar() +*/ + QCalendar QCalendarWidget::calendar() const { Q_D(const QCalendarWidget); return d->m_model->m_calendar; } +/*! + \since 5.14 + Set \a c as the calendar system to be used by this widget. + + The widget can use any supported calendar system. + By default, it uses the Gregorian calendar. + + \sa calendar() +*/ + void QCalendarWidget::setCalendar(QCalendar c) { Q_D(QCalendarWidget); diff --git a/src/widgets/widgets/qcheckbox.cpp b/src/widgets/widgets/qcheckbox.cpp index 88cd603d70..3c03e9efa5 100644 --- a/src/widgets/widgets/qcheckbox.cpp +++ b/src/widgets/widgets/qcheckbox.cpp @@ -93,6 +93,11 @@ public: \fn void QCheckBox::stateChanged(int state) \deprecated [6.9] Use checkStateChanged(Qt::CheckState) instead. + + This signal is emitted whenever the checkbox's state changes, i.e., + whenever the user checks or unchecks it. + + \a state contains the checkbox's new Qt::CheckState. */ /*! diff --git a/src/widgets/widgets/qdatetimeedit.cpp b/src/widgets/widgets/qdatetimeedit.cpp index 01e52b2fa6..a9b5babde5 100644 --- a/src/widgets/widgets/qdatetimeedit.cpp +++ b/src/widgets/widgets/qdatetimeedit.cpp @@ -303,6 +303,12 @@ void QDateTimeEdit::setTime(QTime time) } } +/*! + \since 5.14 + Report the calendar system in use by this widget. + + \sa setCalendar() +*/ QCalendar QDateTimeEdit::calendar() const { @@ -310,6 +316,16 @@ QCalendar QDateTimeEdit::calendar() const return d->calendar; } +/*! + \since 5.14 + Set \a calendar as the calendar system to be used by this widget. + + The widget can use any supported calendar system. + By default, it uses the Gregorian calendar. + + \sa calendar() +*/ + void QDateTimeEdit::setCalendar(QCalendar calendar) { Q_D(QDateTimeEdit); @@ -2462,7 +2478,7 @@ int QDateTimeEditPrivate::absoluteIndex(QDateTimeEdit::Section s, int index) con return NoSectionIndex; } -int QDateTimeEditPrivate::absoluteIndex(const SectionNode &s) const +int QDateTimeEditPrivate::absoluteIndex(SectionNode s) const { return sectionNodes.indexOf(s); } diff --git a/src/widgets/widgets/qdatetimeedit_p.h b/src/widgets/widgets/qdatetimeedit_p.h index 215ee75bfe..f93afd1519 100644 --- a/src/widgets/widgets/qdatetimeedit_p.h +++ b/src/widgets/widgets/qdatetimeedit_p.h @@ -67,7 +67,7 @@ public: int cursorPosition() const override { return edit ? edit->cursorPosition() : -1; } int absoluteIndex(QDateTimeEdit::Section s, int index) const; - int absoluteIndex(const SectionNode &s) const; + int absoluteIndex(SectionNode s) const; QDateTime stepBy(int index, int steps, bool test = false) const; int sectionAt(int pos) const; int closestSection(int index, bool forward) const; diff --git a/src/widgets/widgets/qdialogbuttonbox.cpp b/src/widgets/widgets/qdialogbuttonbox.cpp index 30ace89fa8..0b6a4df41a 100644 --- a/src/widgets/widgets/qdialogbuttonbox.cpp +++ b/src/widgets/widgets/qdialogbuttonbox.cpp @@ -374,7 +374,7 @@ QPushButton *QDialogButtonBoxPrivate::createButton(QDialogButtonBox::StandardBut button->setIcon(style->standardIcon(QStyle::StandardPixmap(icon), nullptr, q)); if (style != QApplication::style()) // Propagate style button->setStyle(style); - standardButtonHash.insert(button, sbutton); + standardButtonMap.insert(button, sbutton); QPlatformDialogHelper::ButtonRole role = QPlatformDialogHelper::buttonRole(static_cast<QPlatformDialogHelper::StandardButton>(sbutton)); if (Q_UNLIKELY(role == QPlatformDialogHelper::InvalidRole)) qWarning("QDialogButtonBox::createButton: Invalid ButtonRole, button not added"); @@ -426,10 +426,10 @@ void QDialogButtonBoxPrivate::createStandardButtons(QDialogButtonBox::StandardBu void QDialogButtonBoxPrivate::retranslateStrings() { - for (auto &&[key, value] : std::as_const(standardButtonHash).asKeyValueRange()) { - const QString text = QGuiApplicationPrivate::platformTheme()->standardButtonText(value); + for (const auto &it : std::as_const(standardButtonMap)) { + const QString text = QGuiApplicationPrivate::platformTheme()->standardButtonText(it.second); if (!text.isEmpty()) - key->setText(text); + it.first->setText(text); } } @@ -644,15 +644,15 @@ void QDialogButtonBox::clear() Q_D(QDialogButtonBox); // Remove the created standard buttons, they should be in the other lists, which will // do the deletion - d->standardButtonHash.clear(); + d->standardButtonMap.clear(); for (int i = 0; i < NRoles; ++i) { QList<QAbstractButton *> &list = d->buttonLists[i]; - while (list.size()) { - QAbstractButton *button = list.takeAt(0); + for (auto button : std::as_const(list)) { QObjectPrivate::disconnect(button, &QAbstractButton::destroyed, d, &QDialogButtonBoxPrivate::handleButtonDestroyed); delete button; } + list.clear(); } } @@ -680,7 +680,11 @@ QList<QAbstractButton *> QDialogButtonBoxPrivate::visibleButtons() const QList<QAbstractButton *> QDialogButtonBoxPrivate::allButtons() const { - return visibleButtons() << hiddenButtons.keys(); + QList<QAbstractButton *> ret(visibleButtons()); + ret.reserve(ret.size() + hiddenButtons.size()); + for (const auto &it : hiddenButtons) + ret.push_back(it.first); + return ret; } /*! @@ -718,9 +722,9 @@ void QDialogButtonBox::removeButton(QAbstractButton *button) Removes \param button. \param reason determines the behavior following the removal: \list - \li \c ManualRemove disconnects all signals and removes the button from standardButtonHash. - \li \c HideEvent keeps connections alive, standard buttons remain in standardButtonHash. - \li \c Destroyed removes the button from standardButtonHash. Signals remain untouched, because + \li \c ManualRemove disconnects all signals and removes the button from standardButtonMap. + \li \c HideEvent keeps connections alive, standard buttons remain in standardButtonMap. + \li \c Destroyed removes the button from standardButtonMap. Signals remain untouched, because the button might already be only a QObject, the destructor of which handles disconnecting. \endlist */ @@ -744,7 +748,7 @@ void QDialogButtonBoxPrivate::removeButton(QAbstractButton *button, RemoveReason button->removeEventFilter(filter.get()); Q_FALLTHROUGH(); case RemoveReason::Destroyed: - standardButtonHash.remove(reinterpret_cast<QPushButton *>(button)); + standardButtonMap.remove(reinterpret_cast<QPushButton *>(button)); break; case RemoveReason::HideEvent: break; @@ -818,8 +822,9 @@ void QDialogButtonBox::setStandardButtons(StandardButtons buttons) { Q_D(QDialogButtonBox); // Clear out all the old standard buttons, then recreate them. - qDeleteAll(d->standardButtonHash.keyBegin(), d->standardButtonHash.keyEnd()); - d->standardButtonHash.clear(); + const auto oldButtons = d->standardButtonMap.keys(); + d->standardButtonMap.clear(); + qDeleteAll(oldButtons); d->createStandardButtons(buttons); } @@ -828,11 +833,8 @@ QDialogButtonBox::StandardButtons QDialogButtonBox::standardButtons() const { Q_D(const QDialogButtonBox); StandardButtons standardButtons = NoButton; - QHash<QPushButton *, StandardButton>::const_iterator it = d->standardButtonHash.constBegin(); - while (it != d->standardButtonHash.constEnd()) { - standardButtons |= it.value(); - ++it; - } + for (const auto value : d->standardButtonMap.values()) + standardButtons |= value; return standardButtons; } @@ -845,7 +847,12 @@ QDialogButtonBox::StandardButtons QDialogButtonBox::standardButtons() const QPushButton *QDialogButtonBox::button(StandardButton which) const { Q_D(const QDialogButtonBox); - return d->standardButtonHash.key(which); + + for (const auto &it : std::as_const(d->standardButtonMap)) { + if (it.second == which) + return it.first; + } + return nullptr; } /*! @@ -857,7 +864,7 @@ QPushButton *QDialogButtonBox::button(StandardButton which) const QDialogButtonBox::StandardButton QDialogButtonBox::standardButton(QAbstractButton *button) const { Q_D(const QDialogButtonBox); - return d->standardButtonHash.value(static_cast<QPushButton *>(button)); + return d->standardButtonMap.value(static_cast<QPushButton *>(button)); } void QDialogButtonBoxPrivate::handleButtonClicked() @@ -965,16 +972,13 @@ bool QDialogButtonBox::centerButtons() const */ void QDialogButtonBox::changeEvent(QEvent *event) { - typedef QHash<QPushButton *, QDialogButtonBox::StandardButton> StandardButtonHash; - Q_D(QDialogButtonBox); switch (event->type()) { case QEvent::StyleChange: // Propagate style - if (!d->standardButtonHash.empty()) { + if (!d->standardButtonMap.empty()) { QStyle *newStyle = style(); - const StandardButtonHash::iterator end = d->standardButtonHash.end(); - for (StandardButtonHash::iterator it = d->standardButtonHash.begin(); it != end; ++it) - it.key()->setStyle(newStyle); + for (auto key : d->standardButtonMap.keys()) + key->setStyle(newStyle); } #ifdef Q_OS_MAC Q_FALLTHROUGH(); diff --git a/src/widgets/widgets/qdialogbuttonbox_p.h b/src/widgets/widgets/qdialogbuttonbox_p.h index c3d7e03489..e439819c49 100644 --- a/src/widgets/widgets/qdialogbuttonbox_p.h +++ b/src/widgets/widgets/qdialogbuttonbox_p.h @@ -16,6 +16,7 @@ // #include <private/qwidget_p.h> +#include <private/qflatmap_p.h> #include <qdialogbuttonbox.h> QT_BEGIN_NAMESPACE @@ -42,8 +43,8 @@ public: QDialogButtonBoxPrivate(Qt::Orientation orient); QList<QAbstractButton *> buttonLists[QDialogButtonBox::NRoles]; - QHash<QPushButton *, QDialogButtonBox::StandardButton> standardButtonHash; - QHash<QAbstractButton *, QDialogButtonBox::ButtonRole> hiddenButtons; + QVarLengthFlatMap<QPushButton *, QDialogButtonBox::StandardButton, 8> standardButtonMap; + QVarLengthFlatMap<QAbstractButton *, QDialogButtonBox::ButtonRole, 8> hiddenButtons; Qt::Orientation orientation; QDialogButtonBox::ButtonLayout layoutPolicy; diff --git a/src/widgets/widgets/qdockwidget.cpp b/src/widgets/widgets/qdockwidget.cpp index 706306000c..f353525553 100644 --- a/src/widgets/widgets/qdockwidget.cpp +++ b/src/widgets/widgets/qdockwidget.cpp @@ -1448,22 +1448,60 @@ QDockWidget::DockWidgetFeatures QDockWidget::features() const void QDockWidget::setFloating(bool floating) { Q_D(QDockWidget); + d->setFloating(floating); +} +/*! + \internal implementation of setFloating + */ +void QDockWidgetPrivate::setFloating(bool floating) +{ + Q_Q(QDockWidget); // the initial click of a double-click may have started a drag... - if (d->state != nullptr) - d->endDrag(QDockWidgetPrivate::EndDragMode::Abort); + if (state != nullptr) + endDrag(QDockWidgetPrivate::EndDragMode::Abort); - QRect r = d->undockedGeometry; // Keep position when undocking for the first time. - if (floating && isVisible() && !r.isValid()) - r = QRect(mapToGlobal(QPoint(0, 0)), size()); + QRect r = undockedGeometry; + if (floating && q->isVisible() && !r.isValid()) + r = QRect(q->mapToGlobal(QPoint(0, 0)), q->size()); + + // Reparent, if setFloating() was called on a floating tab + // Reparenting has to happen before setWindowState. + // The reparented dock widget will inherit visibility from the floating tab. + // => Remember visibility and the necessity to update it. + enum class VisibilityRule { + NoUpdate, + Show, + Hide, + }; + + VisibilityRule updateRule = VisibilityRule::NoUpdate; + + if (floating && !q->isFloating()) { + if (auto *groupWindow = qobject_cast<QDockWidgetGroupWindow *>(q->parentWidget())) { + updateRule = groupWindow->isVisible() ? VisibilityRule::Show : VisibilityRule::Hide; + q->setParent(groupWindow->parentWidget()); + } + } - d->setWindowState(floating, false, floating ? r : QRect()); + setWindowState(floating, false, floating ? r : QRect()); if (floating && r.isNull()) { - if (x() < 0 || y() < 0) //may happen if we have been hidden - move(QPoint()); - setAttribute(Qt::WA_Moved, false); //we want it at the default position + if (q->x() < 0 || q->y() < 0) //may happen if we have been hidden + q->move(QPoint()); + q->setAttribute(Qt::WA_Moved, false); //we want it at the default position + } + + switch (updateRule) { + case VisibilityRule::NoUpdate: + break; + case VisibilityRule::Show: + q->show(); + break; + case VisibilityRule::Hide: + q->hide(); + break; } } diff --git a/src/widgets/widgets/qdockwidget_p.h b/src/widgets/widgets/qdockwidget_p.h index fa936599c6..6d3d307729 100644 --- a/src/widgets/widgets/qdockwidget_p.h +++ b/src/widgets/widgets/qdockwidget_p.h @@ -104,6 +104,7 @@ public: void unplug(const QRect &rect); void plug(const QRect &rect); void setResizerActive(bool active); + void setFloating(bool floating); bool isAnimating() const; bool isTabbed() const; diff --git a/src/widgets/widgets/qframe.cpp b/src/widgets/widgets/qframe.cpp index db8dc20be2..1973fd24ee 100644 --- a/src/widgets/widgets/qframe.cpp +++ b/src/widgets/widgets/qframe.cpp @@ -32,7 +32,13 @@ QFramePrivate::~QFramePrivate() inline void QFramePrivate::init() { + Q_Q(QFrame); setLayoutItemMargins(QStyle::SE_FrameLayoutItem); + + // The frameRect property is implemented in terms of the widget's + // contentsRect, which conflicts with the implicit inclusion of + // the safe area margins in the contentsRect. + q->setAttribute(Qt::WA_ContentsMarginsRespectsSafeArea, false); } /*! diff --git a/src/widgets/widgets/qlineedit.cpp b/src/widgets/widgets/qlineedit.cpp index 8909ac80d9..0db46bf175 100644 --- a/src/widgets/widgets/qlineedit.cpp +++ b/src/widgets/widgets/qlineedit.cpp @@ -2211,11 +2211,13 @@ QMenu *QLineEdit::createStandardContextMenu() if (!isReadOnly()) { action = popup->addAction(QLineEdit::tr("&Undo") + ACCEL_KEY(QKeySequence::Undo)); action->setEnabled(d->control->isUndoAvailable()); + action->setObjectName(QStringLiteral("edit-undo")); setActionIcon(action, QStringLiteral("edit-undo")); connect(action, &QAction::triggered, this, &QLineEdit::undo); action = popup->addAction(QLineEdit::tr("&Redo") + ACCEL_KEY(QKeySequence::Redo)); action->setEnabled(d->control->isRedoAvailable()); + action->setObjectName(QStringLiteral("edit-redo")); setActionIcon(action, QStringLiteral("edit-redo")); connect(action, &QAction::triggered, this, &QLineEdit::redo); @@ -2227,6 +2229,7 @@ QMenu *QLineEdit::createStandardContextMenu() action = popup->addAction(QLineEdit::tr("Cu&t") + ACCEL_KEY(QKeySequence::Cut)); action->setEnabled(!d->control->isReadOnly() && d->control->hasSelectedText() && d->control->echoMode() == QLineEdit::Normal); + action->setObjectName(QStringLiteral("edit-cut")); setActionIcon(action, QStringLiteral("edit-cut")); connect(action, &QAction::triggered, this, &QLineEdit::cut); } @@ -2234,12 +2237,14 @@ QMenu *QLineEdit::createStandardContextMenu() action = popup->addAction(QLineEdit::tr("&Copy") + ACCEL_KEY(QKeySequence::Copy)); action->setEnabled(d->control->hasSelectedText() && d->control->echoMode() == QLineEdit::Normal); + action->setObjectName(QStringLiteral("edit-copy")); setActionIcon(action, QStringLiteral("edit-copy")); connect(action, &QAction::triggered, this, &QLineEdit::copy); if (!isReadOnly()) { action = popup->addAction(QLineEdit::tr("&Paste") + ACCEL_KEY(QKeySequence::Paste)); action->setEnabled(!d->control->isReadOnly() && !QGuiApplication::clipboard()->text().isEmpty()); + action->setObjectName(QStringLiteral("edit-paste")); setActionIcon(action, QStringLiteral("edit-paste")); connect(action, &QAction::triggered, this, &QLineEdit::paste); } @@ -2248,6 +2253,7 @@ QMenu *QLineEdit::createStandardContextMenu() if (!isReadOnly()) { action = popup->addAction(QLineEdit::tr("Delete")); action->setEnabled(!d->control->isReadOnly() && !d->control->text().isEmpty() && d->control->hasSelectedText()); + action->setObjectName(QStringLiteral("edit-delete")); setActionIcon(action, QStringLiteral("edit-delete")); connect(action, &QAction::triggered, d->control, &QWidgetLineControl::_q_deleteSelected); @@ -2258,6 +2264,7 @@ QMenu *QLineEdit::createStandardContextMenu() action = popup->addAction(QLineEdit::tr("Select All") + ACCEL_KEY(QKeySequence::SelectAll)); action->setEnabled(!d->control->text().isEmpty() && !d->control->allSelected()); + action->setObjectName(QStringLiteral("select-all")); setActionIcon(action, QStringLiteral("edit-select-all")); d->selectAllAction = action; connect(action, &QAction::triggered, this, &QLineEdit::selectAll); diff --git a/src/widgets/widgets/qmainwindowlayout.cpp b/src/widgets/widgets/qmainwindowlayout.cpp index db17e50d5c..1a365dbb6e 100644 --- a/src/widgets/widgets/qmainwindowlayout.cpp +++ b/src/widgets/widgets/qmainwindowlayout.cpp @@ -37,7 +37,6 @@ #include <qvarlengtharray.h> #include <qstack.h> #include <qmap.h> -#include <qtimer.h> #include <qpointer.h> #ifndef QT_NO_DEBUG_STREAM @@ -1931,6 +1930,11 @@ bool QMainWindowTabBar::contains(const QDockWidget *dockWidget) const return false; } +// When a dock widget is removed from a floating tab, +// Events need to be processed for the tab bar to realize that the dock widget is gone. +// In this case count() counts the dock widget in transition and accesses dockAt +// with an out-of-bounds index. +// => return nullptr in contrast to other xxxxxAt() functions QDockWidget *QMainWindowTabBar::dockAt(int index) const { QMainWindowTabBar *that = const_cast<QMainWindowTabBar *>(this); @@ -1938,10 +1942,39 @@ QDockWidget *QMainWindowTabBar::dockAt(int index) const QDockAreaLayoutInfo *info = mlayout->dockInfo(that); if (!info) return nullptr; + const int itemIndex = info->tabIndexToListIndex(index); - Q_ASSERT(itemIndex >= 0 && itemIndex < info->item_list.count()); - const QDockAreaLayoutItem &item = info->item_list.at(itemIndex); - return item.widgetItem ? qobject_cast<QDockWidget *>(item.widgetItem->widget()) : nullptr; + if (itemIndex >= 0) { + Q_ASSERT(itemIndex < info->item_list.count()); + const QDockAreaLayoutItem &item = info->item_list.at(itemIndex); + return item.widgetItem ? qobject_cast<QDockWidget *>(item.widgetItem->widget()) : nullptr; + } + + return nullptr; +} + +/*! + \internal + Move \a dockWidget to its ideal unplug position. + \list + \li If \a dockWidget has a title bar widget, place its center under the mouse cursor. + \li Otherwise place it in the middle of the title bar's long side, with a + QApplication::startDragDistance() offset on the short side. + \endlist + */ +static void moveToUnplugPosition(QPoint mouse, QDockWidget *dockWidget) +{ + Q_ASSERT(dockWidget); + + if (auto *tbWidget = dockWidget->titleBarWidget()) { + dockWidget->move(mouse - tbWidget->rect().center()); + return; + } + + const bool vertical = dockWidget->features().testFlag(QDockWidget::DockWidgetVerticalTitleBar); + const int deltaX = vertical ? QApplication::startDragDistance() : dockWidget->width() / 2; + const int deltaY = vertical ? dockWidget->height() / 2 : QApplication::startDragDistance(); + dockWidget->move(mouse - QPoint(deltaX, deltaY)); } void QMainWindowTabBar::mouseMoveEvent(QMouseEvent *e) @@ -1981,9 +2014,8 @@ void QMainWindowTabBar::mouseMoveEvent(QMouseEvent *e) if (draggingDock) { QDockWidgetPrivate *dockPriv = static_cast<QDockWidgetPrivate *>(QObjectPrivate::get(draggingDock)); if (dockPriv->state && dockPriv->state->dragging) { - QPoint pos = e->globalPosition().toPoint() - dockPriv->state->pressPos; - draggingDock->move(pos); // move will call QMainWindowLayout::hover + moveToUnplugPosition(e->globalPosition().toPoint(), draggingDock); } } QTabBar::mouseMoveEvent(e); diff --git a/src/widgets/widgets/qplaintextedit.cpp b/src/widgets/widgets/qplaintextedit.cpp index 8362c6c629..77279c8749 100644 --- a/src/widgets/widgets/qplaintextedit.cpp +++ b/src/widgets/widgets/qplaintextedit.cpp @@ -17,7 +17,6 @@ #include <qmenu.h> #endif #include <qstyle.h> -#include <qtimer.h> #include "private/qapplication_p.h" #include "private/qtextdocumentlayout_p.h" #include "private/qabstracttextdocumentlayout_p.h" diff --git a/src/widgets/widgets/qrubberband.cpp b/src/widgets/widgets/qrubberband.cpp index e00f739ca7..f0251b71cb 100644 --- a/src/widgets/widgets/qrubberband.cpp +++ b/src/widgets/widgets/qrubberband.cpp @@ -5,7 +5,6 @@ #include "qevent.h" #include "qstylepainter.h" #include "qrubberband.h" -#include "qtimer.h" #include "qstyle.h" #include "qstyleoption.h" diff --git a/src/widgets/widgets/qsplitter.cpp b/src/widgets/widgets/qsplitter.cpp index d0519a56a2..45f0c3895d 100644 --- a/src/widgets/widgets/qsplitter.cpp +++ b/src/widgets/widgets/qsplitter.cpp @@ -19,7 +19,6 @@ #include "qvarlengtharray.h" #include "private/qlayoutengine_p.h" #include "private/qsplitter_p.h" -#include "qtimer.h" #include "qdebug.h" #include <ctype.h> diff --git a/src/widgets/widgets/qtextedit.cpp b/src/widgets/widgets/qtextedit.cpp index 90884dd438..90f09fcb79 100644 --- a/src/widgets/widgets/qtextedit.cpp +++ b/src/widgets/widgets/qtextedit.cpp @@ -21,7 +21,6 @@ #include <qmenu.h> #endif #include <qstyle.h> -#include <qtimer.h> #if QT_CONFIG(accessibility) #include <qaccessible.h> #endif diff --git a/src/widgets/widgets/qtoolbar.cpp b/src/widgets/widgets/qtoolbar.cpp index 5e5ef8e8d5..0d386a4378 100644 --- a/src/widgets/widgets/qtoolbar.cpp +++ b/src/widgets/widgets/qtoolbar.cpp @@ -25,7 +25,6 @@ #include <qstyleoption.h> #include <qtoolbutton.h> #include <qwidgetaction.h> -#include <qtimer.h> #include <private/qwidgetaction_p.h> #include <private/qmainwindowlayout_p.h> #include <private/qhighdpiscaling_p.h> diff --git a/src/widgets/widgets/qtoolbar_p.h b/src/widgets/widgets/qtoolbar_p.h index 2561cd8f64..9ebce6fdfd 100644 --- a/src/widgets/widgets/qtoolbar_p.h +++ b/src/widgets/widgets/qtoolbar_p.h @@ -26,7 +26,6 @@ QT_REQUIRE_CONFIG(toolbar); QT_BEGIN_NAMESPACE class QToolBarLayout; -class QTimer; class QToolBarPrivate : public QWidgetPrivate { diff --git a/src/widgets/widgets/qwidgettextcontrol.cpp b/src/widgets/widgets/qwidgettextcontrol.cpp index 6dcaeee0c8..96f2ec22ff 100644 --- a/src/widgets/widgets/qwidgettextcontrol.cpp +++ b/src/widgets/widgets/qwidgettextcontrol.cpp @@ -15,7 +15,6 @@ #endif #include <qclipboard.h> #include <qstyle.h> -#include <qtimer.h> #include "private/qapplication_p.h" #include "private/qtextdocumentlayout_p.h" #include "private/qabstracttextdocumentlayout_p.h" |