diff options
Diffstat (limited to 'src/plugins/platforms/windows/qwindowswindow.h')
-rw-r--r-- | src/plugins/platforms/windows/qwindowswindow.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/plugins/platforms/windows/qwindowswindow.h b/src/plugins/platforms/windows/qwindowswindow.h index 9ed6197eae..024711e7f3 100644 --- a/src/plugins/platforms/windows/qwindowswindow.h +++ b/src/plugins/platforms/windows/qwindowswindow.h @@ -78,6 +78,7 @@ struct QWindowsWindowData { Qt::WindowFlags flags; QRect geometry; + QRect restoreGeometry; QMargins fullFrameMargins; // Do not use directly for windows, see FrameDirty. QMargins customMargins; // User-defined, additional frame for NCCALCSIZE HWND hwnd = nullptr; @@ -218,6 +219,8 @@ public: void setGeometry(const QRect &rect) override; QRect geometry() const override { return m_data.geometry; } QRect normalGeometry() const override; + QRect restoreGeometry() const { return m_data.restoreGeometry; } + void updateRestoreGeometry(); void setVisible(bool visible) override; bool isVisible() const; @@ -272,7 +275,7 @@ public: QWindowsMenuBar *menuBar() const; void setMenuBar(QWindowsMenuBar *mb); - QMargins customMargins() const override { return m_data.customMargins; } + QMargins customMargins() const override; void setCustomMargins(const QMargins &m) override; void setStyle(unsigned s) const; @@ -281,11 +284,12 @@ public: bool handleWmPaint(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam, LRESULT *result); void handleMoved(); - void handleResized(int wParam); + void handleResized(int wParam, LPARAM lParam); void handleHidden(); void handleCompositionSettingsChanged(); void handleDpiScaledSize(WPARAM wParam, LPARAM lParam, LRESULT *result); void handleDpiChanged(HWND hwnd, WPARAM wParam, LPARAM lParam); + void handleDpiChangedAfterParent(HWND hwnd); static void displayChanged(); static void settingsChanged(); @@ -295,6 +299,7 @@ public: static inline void *userDataOf(HWND hwnd); static inline void setUserDataOf(HWND hwnd, void *ud); + static bool hasNoNativeFrame(HWND hwnd, Qt::WindowFlags flags); static bool setWindowLayered(HWND hwnd, Qt::WindowFlags flags, bool hasAlpha, qreal opacity); bool isLayered() const; @@ -319,7 +324,6 @@ public: void *surface(void *nativeConfig, int *err); void invalidateSurface() override; - void aboutToMakeCurrent(); void setAlertState(bool enabled) override; bool isAlertState() const override { return testFlag(AlertState); } @@ -341,6 +345,7 @@ public: void setSavedDpi(int dpi) { m_savedDpi = dpi; } int savedDpi() const { return m_savedDpi; } + qreal dpiRelativeScale(const UINT dpi) const; private: inline void show_sys() const; |