summaryrefslogtreecommitdiffhomepage
path: root/dinput
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2021-12-15 15:29:46 +0100
committerStanislaw Halik <sthalik@misaki.pl>2021-12-16 15:32:03 +0100
commitaa3d6dd09fb2ecf4a5bf91536ca67b4f71b24613 (patch)
tree50d55ab1822ba68733325955ce6be24d82752a87 /dinput
parent94cdd29400d739fcec664266537ecf3904a8476d (diff)
many: switch from using std::unique_ptr<t>::get() to &*ptr
Diffstat (limited to 'dinput')
-rw-r--r--dinput/keybinding-worker.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/dinput/keybinding-worker.cpp b/dinput/keybinding-worker.cpp
index 0ceca789..91b02428 100644
--- a/dinput/keybinding-worker.cpp
+++ b/dinput/keybinding-worker.cpp
@@ -225,7 +225,7 @@ KeybindingWorker::fun* KeybindingWorker::add_receiver(fun& receiver)
{
QMutexLocker l(&mtx);
receivers.push_back(std::make_unique<fun>(receiver));
- fun* f = receivers[receivers.size() - 1].get();
+ fun* f = &*receivers[receivers.size() - 1];
//qDebug() << "add receiver" << (long) f;
joy_ctx.refresh();
return f;
@@ -241,7 +241,7 @@ void KeybindingWorker::remove_receiver(KeybindingWorker::fun* pos)
for (int i = s(receivers.size()) - 1; i >= 0; i--)
{
using u = unsigned;
- if (receivers[u(i)].get() == pos)
+ if (&*receivers[u(i)] == pos)
{
ok = true;
//qDebug() << "remove receiver" << (long) pos;