diff options
author | bunnei <bunneidev@gmail.com> | 2020-05-03 23:16:19 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-03 23:16:19 -0400 |
commit | fc04108c77be13cc1ba7402225243253cee7cbf2 (patch) | |
tree | 6c8f7d08a8146f9ca5b023920b82071596946568 /src/yuzu/bootmanager.cpp | |
parent | 29fce1a1872909f7200a3b727adcc3dfb71013a1 (diff) | |
parent | e7664b7a4fe1035bc3c9afb51254bfff1f25654a (diff) |
Merge pull request #3637 from FearlessTobi/port-5094
Port citra-emu/citra#5094: "yuzu: Option to hide mouse on inactivity"
Diffstat (limited to 'src/yuzu/bootmanager.cpp')
-rw-r--r-- | src/yuzu/bootmanager.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/yuzu/bootmanager.cpp b/src/yuzu/bootmanager.cpp index 1cac2f942..3d759f77b 100644 --- a/src/yuzu/bootmanager.cpp +++ b/src/yuzu/bootmanager.cpp @@ -292,6 +292,8 @@ GRenderWindow::GRenderWindow(GMainWindow* parent_, EmuThread* emu_thread_) setLayout(layout); InputCommon::Init(); + this->setMouseTracking(true); + connect(this, &GRenderWindow::FirstFrameDisplayed, parent_, &GMainWindow::OnLoadComplete); } @@ -385,6 +387,7 @@ void GRenderWindow::mousePressEvent(QMouseEvent* event) { } else if (event->button() == Qt::RightButton) { InputCommon::GetMotionEmu()->BeginTilt(pos.x(), pos.y()); } + QWidget::mousePressEvent(event); } void GRenderWindow::mouseMoveEvent(QMouseEvent* event) { @@ -397,6 +400,7 @@ void GRenderWindow::mouseMoveEvent(QMouseEvent* event) { const auto [x, y] = ScaleTouch(pos); this->TouchMoved(x, y); InputCommon::GetMotionEmu()->Tilt(pos.x(), pos.y()); + QWidget::mouseMoveEvent(event); } void GRenderWindow::mouseReleaseEvent(QMouseEvent* event) { |