1
0
Fork 0

some performance tuning

Just call Websockets only if really needed by shown tabs
main
Kim Huebel 4 years ago
parent e7c6823a6e
commit bffbf8ee6e

@ -291,10 +291,12 @@
"order": [[ 0, "desc" ]] "order": [[ 0, "desc" ]]
} ); } );
var ws3 = new WebSocket("ws://" + window.location.hostname + ":5678/SYSINFO"); if (showSysInfoTab) {
ws3.onmessage = function (event) { var ws3 = new WebSocket("ws://" + window.location.hostname + ":5678/SYSINFO");
getSysInfo(document, event); ws3.onmessage = function (event) {
}; getSysInfo(document, event);
};
}
var ws1 = new WebSocket("ws://" + window.location.hostname + ":5678/MMDVM"); var ws1 = new WebSocket("ws://" + window.location.hostname + ":5678/MMDVM");
ws1.onmessage = function (event) { ws1.onmessage = function (event) {
@ -323,12 +325,13 @@
t_qso.row('.selected').remove().draw( false ); t_qso.row('.selected').remove().draw( false );
} ); } );
var ws2 = new WebSocket("ws://" + window.location.hostname + ":5678/DAPNET"); if (showDAPNETMessagesTab) {
ws2.onmessage = function (event) { var ws2 = new WebSocket("ws://" + window.location.hostname + ":5678/DAPNET");
getDapnetMessages(document, event); ws2.onmessage = function (event) {
}; getDapnetMessages(document, event);
t_dapnet.order( [ 0, 'desc' ] ).draw(); };
t_dapnet.order( [ 0, 'desc' ] ).draw();
}
</script> </script>
</body> </body>
</html> </html>

Loading…
Cancel
Save