mirror of
https://github.com/rustdesk/rustdesk.git
synced 2024-12-12 10:19:09 +08:00
ready to handle video
This commit is contained in:
parent
7208364785
commit
3dcbbcc416
@ -20,6 +20,7 @@ export default class Connection {
|
||||
_hash: message.Hash | undefined;
|
||||
_msgbox: MsgboxCallback | undefined;
|
||||
_peerInfo: message.PeerInfo | undefined;
|
||||
_firstFrame: Boolean | undefined;
|
||||
|
||||
constructor() {
|
||||
this._msgs = [];
|
||||
@ -179,6 +180,8 @@ export default class Connection {
|
||||
this._peerInfo = r.peerInfo;
|
||||
this.msgbox('success', 'Successful', 'Connected, waiting for image...');
|
||||
}
|
||||
} else if (msg?.videoFrame) {
|
||||
this.handleVideoFrame();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -222,6 +225,13 @@ export default class Connection {
|
||||
});
|
||||
await this._ws?.sendMessage({ loginRequest });
|
||||
}
|
||||
|
||||
handleVideoFrame() {
|
||||
if (!this._firstFrame) {
|
||||
this.msgbox('', '', '');
|
||||
this._firstFrame = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
async function testDelay() {
|
||||
|
Loading…
Reference in New Issue
Block a user