Introduce "Maximize/restore" title bar button support

As happens with other docking frameworks:
- Maximized/restore button only visible when window is floating
- floating button is never visible

Available by setting Flag_TitleBarHasMaximizeButton.
Added example too.

Fixes: #37
This commit is contained in:
Sergio Martins
2020-04-20 19:54:03 +01:00
parent ab0fc1e328
commit 6ee3cfbb2d
9 changed files with 81 additions and 6 deletions

View File

@@ -38,6 +38,7 @@ public:
protected:
void paintEvent(QPaintEvent *) override;
bool event(QEvent *ev) override;
private:
void init();
Q_DISABLE_COPY(FloatingWindowWidget)