mirror of
https://github.com/feschber/lan-mouse.git
synced 2026-04-20 09:43:19 +03:00
fix update pos
This commit is contained in:
committed by
Ferdinand Schober
parent
4d835a5190
commit
60fab82423
@@ -231,7 +231,7 @@ impl Service {
|
|||||||
event = emulation.event() => match event {
|
event = emulation.event() => match event {
|
||||||
EmulationEvent::Connected { addr, pos, fingerprint } => {
|
EmulationEvent::Connected { addr, pos, fingerprint } => {
|
||||||
// check if already registered
|
// check if already registered
|
||||||
if self.incoming_conns.borrow_mut().insert(addr) {
|
if !self.incoming_conns.borrow_mut().contains(&addr) {
|
||||||
self.add_incoming(addr, pos, fingerprint.clone(), &capture);
|
self.add_incoming(addr, pos, fingerprint.clone(), &capture);
|
||||||
self.notify_frontend(FrontendEvent::IncomingConnected(fingerprint, addr, pos));
|
self.notify_frontend(FrontendEvent::IncomingConnected(fingerprint, addr, pos));
|
||||||
} else {
|
} else {
|
||||||
@@ -343,6 +343,7 @@ impl Service {
|
|||||||
let handle = Self::ENTER_HANDLE_BEGIN + self.next_trigger_handle;
|
let handle = Self::ENTER_HANDLE_BEGIN + self.next_trigger_handle;
|
||||||
self.next_trigger_handle += 1;
|
self.next_trigger_handle += 1;
|
||||||
capture.create(handle, pos);
|
capture.create(handle, pos);
|
||||||
|
self.incoming_conns.borrow_mut().insert(addr);
|
||||||
self.incoming_conn_info.borrow_mut().insert(
|
self.incoming_conn_info.borrow_mut().insert(
|
||||||
handle,
|
handle,
|
||||||
Incoming {
|
Incoming {
|
||||||
|
|||||||
Reference in New Issue
Block a user