summaryrefslogtreecommitdiffstats
path: root/src/input_common/helpers/joycon_driver.h
diff options
context:
space:
mode:
authorgerman77 <juangerman-13@hotmail.com>2023-01-14 06:29:05 +0100
committerNarr the Reg <juangerman-13@hotmail.com>2023-01-20 07:51:45 +0100
commit340f15d1fa79594dbe12a6e19140ba012751b533 (patch)
tree7a9ef54a17f927e4b8cf98dd32dd6d41c0d75201 /src/input_common/helpers/joycon_driver.h
parentcore: hid: Only set the polling mode to the correct side (diff)
downloadyuzu-340f15d1fa79594dbe12a6e19140ba012751b533.tar
yuzu-340f15d1fa79594dbe12a6e19140ba012751b533.tar.gz
yuzu-340f15d1fa79594dbe12a6e19140ba012751b533.tar.bz2
yuzu-340f15d1fa79594dbe12a6e19140ba012751b533.tar.lz
yuzu-340f15d1fa79594dbe12a6e19140ba012751b533.tar.xz
yuzu-340f15d1fa79594dbe12a6e19140ba012751b533.tar.zst
yuzu-340f15d1fa79594dbe12a6e19140ba012751b533.zip
Diffstat (limited to 'src/input_common/helpers/joycon_driver.h')
-rw-r--r--src/input_common/helpers/joycon_driver.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/input_common/helpers/joycon_driver.h b/src/input_common/helpers/joycon_driver.h
index e8e65e133..c1e189fa5 100644
--- a/src/input_common/helpers/joycon_driver.h
+++ b/src/input_common/helpers/joycon_driver.h
@@ -3,6 +3,7 @@
#pragma once
+#include <atomic>
#include <functional>
#include <mutex>
#include <span>
@@ -97,7 +98,7 @@ private:
std::unique_ptr<RumbleProtocol> rumble_protocol;
// Connection status
- bool is_connected{};
+ std::atomic<bool> is_connected{};
u64 delta_time;
std::size_t error_counter{};
std::shared_ptr<JoyconHandle> hidapi_handle;