[fix] restore Windows remote control after RDP disconnects

This commit is contained in:
dijunkun
2026-10-16 18:20:45 +08:00
parent 40670de954
commit 0901d61533
14 changed files with 380 additions and 32 deletions
@@ -436,6 +436,12 @@ void PeerEventHandler::OnConnectionStatus(ConnectionStatus status,
runtime->ApplyPrivacyAdmission(automatic_enable);
}
runtime->connection_status_[remote_id] = status;
#if _WIN32
runtime->windows_rdp_handoff_connected_->store(std::any_of(
runtime->connection_status_.begin(), runtime->connection_status_.end(),
[](const auto& entry) { return entry.second == ConnectionStatus::Connected; }),
std::memory_order_relaxed);
#endif
runtime->devices_.OnControllerConnectionsChanged();
}