diff options
Diffstat (limited to 'src/widgets/kernel/qwidget.h')
-rw-r--r-- | src/widgets/kernel/qwidget.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/widgets/kernel/qwidget.h b/src/widgets/kernel/qwidget.h index 4e5ef5a111..83a6e6d4b3 100644 --- a/src/widgets/kernel/qwidget.h +++ b/src/widgets/kernel/qwidget.h @@ -85,6 +85,7 @@ class QDragEnterEvent; class QDragMoveEvent; class QDragLeaveEvent; class QDropEvent; +class QScreen; class QShowEvent; class QHideEvent; class QIcon; @@ -524,7 +525,10 @@ public: void setContentsMargins(int left, int top, int right, int bottom); void setContentsMargins(const QMargins &margins); +#if QT_DEPRECATED_SINCE(5, 14) + QT_DEPRECATED_X("use contentsMargins()") void getContentsMargins(int *left, int *top, int *right, int *bottom) const; +#endif QMargins contentsMargins() const; QRect contentsRect() const; @@ -555,7 +559,7 @@ public: void addAction(QAction *action); #if QT_VERSION >= QT_VERSION_CHECK(6,0,0) void addActions(const QList<QAction*> &actions); - void insertActions(const QAction *before, const QList<QAction*> &actions); + void insertActions(QAction *before, const QList<QAction*> &actions); #else void addActions(QList<QAction*> actions); void insertActions(QAction *before, QList<QAction*> actions); @@ -598,6 +602,7 @@ public: QBackingStore *backingStore() const; QWindow *windowHandle() const; + QScreen *screen() const; static QWidget *createWindowContainer(QWindow *window, QWidget *parent=nullptr, Qt::WindowFlags flags=Qt::WindowFlags()); @@ -648,7 +653,12 @@ protected: virtual void showEvent(QShowEvent *event); virtual void hideEvent(QHideEvent *event); + +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) + virtual bool nativeEvent(const QByteArray &eventType, void *message, qintptr *result); +#else virtual bool nativeEvent(const QByteArray &eventType, void *message, long *result); +#endif // Misc. protected functions virtual void changeEvent(QEvent *); @@ -689,7 +699,7 @@ private: QLayout *takeLayout(); friend class QBackingStoreDevice; - friend class QWidgetBackingStore; + friend class QWidgetRepaintManager; friend class QApplication; friend class QApplicationPrivate; friend class QGuiApplication; |