mirror of
https://github.com/barry-ran/QtScrcpy.git
synced 2025-08-03 06:08:39 +00:00
fix: grab rect dpi error
This commit is contained in:
parent
ccba6c7495
commit
2c015358f7
1 changed files with 2 additions and 2 deletions
|
@ -90,8 +90,8 @@ QRect VideoForm::getGrabCursorRect()
|
||||||
#if defined(Q_OS_WIN32)
|
#if defined(Q_OS_WIN32)
|
||||||
rc = QRect(ui->keepRatioWidget->mapToGlobal(m_videoWidget->pos()), m_videoWidget->size());
|
rc = QRect(ui->keepRatioWidget->mapToGlobal(m_videoWidget->pos()), m_videoWidget->size());
|
||||||
// high dpi support
|
// high dpi support
|
||||||
rc.setTopLeft(rc.topLeft() * m_videoWidget->devicePixelRatio());
|
rc.setTopLeft(rc.topLeft() * m_videoWidget->devicePixelRatioF());
|
||||||
rc.setBottomRight(rc.bottomRight() * m_videoWidget->devicePixelRatio());
|
rc.setBottomRight(rc.bottomRight() * m_videoWidget->devicePixelRatioF());
|
||||||
|
|
||||||
rc.setX(rc.x() + 10);
|
rc.setX(rc.x() + 10);
|
||||||
rc.setY(rc.y() + 10);
|
rc.setY(rc.y() + 10);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue