refactor(FramelessWindow): use Qt API for window resizing (#81)

No longer use Win32API for window resizing. This should work under all platforms that support window resizing.
This commit is contained in:
2023-06-24 14:37:54 +08:00
committed by GitHub
parent 6f28878837
commit 6fc9534184
3 changed files with 114 additions and 90 deletions

View File

@ -162,6 +162,13 @@ MainWindow::MainWindow(QWidget *parent)
QTimer::singleShot(0, this, [this](){
m_am->setupShortcuts();
});
// allow some mouse events can go through these widgets for resizing window.
installResizeCapture(m_closeButton);
installResizeCapture(m_graphicsView);
installResizeCapture(m_graphicsView->viewport());
installResizeCapture(m_gv);
installResizeCapture(m_gv->viewport());
}
MainWindow::~MainWindow()