Allow WidgetResizeHandler to act on global event filter

Needed for widgets which are not top-levels
This commit is contained in:
Sergio Martins
2020-12-17 19:32:59 +00:00
parent c481875e55
commit 4635405fb5
3 changed files with 25 additions and 12 deletions

View File

@@ -47,7 +47,7 @@ public:
* @brief CTOR
* @param target The target widget that will be resized. Also acts as parent QObject.
*/
explicit WidgetResizeHandler(QWidgetOrQuick *target = nullptr);
explicit WidgetResizeHandler(bool filterIsGlobal, QWidgetOrQuick *target);
~WidgetResizeHandler() override;
#ifdef Q_OS_WIN
@@ -68,6 +68,7 @@ private:
CursorPosition mCursorPos = CursorPosition_Undefined;
QPoint mNewPosition;
bool mResizeWidget = false;
const bool mFilterIsGlobal;
};
}