summaryrefslogtreecommitdiffstats
path: root/src/yuzu
diff options
context:
space:
mode:
authorgerman <german@thesoftwareartisans.com>2021-01-10 15:36:31 +0100
committergerman <german@thesoftwareartisans.com>2021-01-15 16:05:17 +0100
commitb483f2d010bf745ab873e8f8bfaca5515e56d39f (patch)
treed14bc19b4ca1c60460a941db612195be12f16b0d /src/yuzu
parentAdd mutitouch support for touch screens (diff)
downloadyuzu-b483f2d010bf745ab873e8f8bfaca5515e56d39f.tar
yuzu-b483f2d010bf745ab873e8f8bfaca5515e56d39f.tar.gz
yuzu-b483f2d010bf745ab873e8f8bfaca5515e56d39f.tar.bz2
yuzu-b483f2d010bf745ab873e8f8bfaca5515e56d39f.tar.lz
yuzu-b483f2d010bf745ab873e8f8bfaca5515e56d39f.tar.xz
yuzu-b483f2d010bf745ab873e8f8bfaca5515e56d39f.tar.zst
yuzu-b483f2d010bf745ab873e8f8bfaca5515e56d39f.zip
Diffstat (limited to 'src/yuzu')
-rw-r--r--src/yuzu/bootmanager.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/yuzu/bootmanager.cpp b/src/yuzu/bootmanager.cpp
index 1f91514ef..4528eb196 100644
--- a/src/yuzu/bootmanager.cpp
+++ b/src/yuzu/bootmanager.cpp
@@ -475,7 +475,7 @@ bool GRenderWindow::TouchStart(const QTouchEvent::TouchPoint& touch_point) {
bool GRenderWindow::TouchUpdate(const QTouchEvent::TouchPoint& touch_point) {
for (std::size_t id = 0; id < touch_ids.size(); ++id) {
- if (touch_ids[id] == touch_point.id() + 1) {
+ if (touch_ids[id] == static_cast<std::size_t>(touch_point.id() + 1)) {
const auto [x, y] = ScaleTouch(touch_point.pos());
this->TouchMoved(x, y, id + 1);
return true;
@@ -486,8 +486,9 @@ bool GRenderWindow::TouchUpdate(const QTouchEvent::TouchPoint& touch_point) {
bool GRenderWindow::TouchExist(std::size_t id,
const QList<QTouchEvent::TouchPoint>& touch_points) const {
- return std::any_of(touch_points.begin(), touch_points.end(),
- [id](const auto& point) { return id == point.id() + 1; });
+ return std::any_of(touch_points.begin(), touch_points.end(), [id](const auto& point) {
+ return id == static_cast<std::size_t>(point.id() + 1);
+ });
}
bool GRenderWindow::event(QEvent* event) {