ADV-Plugin/qml/WSocket.qml
mashiros d0aed6f101 - 增加服务器参数设置对话框
- 优化服务器程序的错误捕捉与日志输出
- 优化翻译
2022-05-12 20:13:25 +08:00

21 lines
417 B
QML

import QtWebSockets 1.1
import "."
WebSocket {
url: "ws://" + Common.wsIp + ":" + Common.wsPort
active: true
onStatusChanged: {
if(status === WebSocket.Closed || status === WebSocket.Error) {
Common.rebootFlag = true;
}
}
onBinaryMessageReceived: {
let arrayBuffer = new Float32Array(message);
Common.audioDataUpdated(arrayBuffer.slice());
}
}