fix(wayland): use system move (#6573)
Reviewed-by: pajlada <rasmus.karlsson@pajlada.com>
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
#include <QKeySequence>
|
||||
#include <QMessageBox>
|
||||
#include <QSizeGrip>
|
||||
#include <QWindow>
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
# include <Windows.h>
|
||||
@@ -232,6 +233,10 @@ bool OverlayWindow::eventFilter(QObject * /*object*/, QEvent *event)
|
||||
switch (event->type())
|
||||
{
|
||||
case QEvent::MouseButtonPress: {
|
||||
if (this->windowHandle()->startSystemMove())
|
||||
{
|
||||
return true;
|
||||
}
|
||||
auto *evt = dynamic_cast<QMouseEvent *>(event);
|
||||
this->moving_ = true;
|
||||
this->moveOrigin_ = evt->globalPosition().toPoint();
|
||||
|
||||
Reference in New Issue
Block a user