Watch
1
0
Fork
You've already forked souveraine
0

face: keep knocking until the rig answers

This commit is contained in:
Fimeg 2026-08-11 14:03:23 -04:00
commit 5afa132ff4

View file

@ -382,16 +382,8 @@ Singleton {
connected: false
onConnectionStateChanged: {
if (sock.connected) {
if (sock.connected)
pageReadyTimer.restart();
} else if (root.joined) {
faceConnectTimer.restart();
}
}
onError: error => {
if (root.joined)
faceConnectTimer.restart();
}
}
@ -399,22 +391,18 @@ Singleton {
target: root
function onJoinedChanged() {
if (root.joined) {
faceConnectTimer.restart();
} else {
faceConnectTimer.stop();
if (!root.joined)
sock.connected = false;
}
}
}
Timer {
id: faceConnectTimer
interval: 200
repeat: false
repeat: true
triggeredOnStart: true
running: root.joined && !sock.connected
onTriggered: {
if (!root.joined || sock.connected)
return;
// A failed QLocalSocket does not retry merely because the desired
// value remained true. Give it a fresh false -> true edge after
// the host has had another moment to bind.