Add a friendly error message when no video traffic is received

This commit is contained in:
Cameron Gutman committed 2020-05-01 21:34:25 -07:00
1 parent 7174ad265d
commit 8a962927ed
2 files changed
+6 -1

No files matched your search

+5
View File
@@ -43,8 +43,13 @@ function handleMessage(msg) {
// Show a termination snackbar message if the termination was unexpected // Show a termination snackbar message if the termination was unexpected
var errorCode = parseInt(msg.data.replace('streamTerminated: ', '')); var errorCode = parseInt(msg.data.replace('streamTerminated: ', ''));
if (errorCode !== 0) { if (errorCode !== 0) {
if (errorCode === -100) { // ML_ERROR_NO_VIDEO_TRAFFIC
snackbarLogLong("No video received from host. Check the host PC's firewall and port forwarding rules.");
}
else {
snackbarLogLong("Connection terminated"); snackbarLogLong("Connection terminated");
} }
}
api.refreshServerInfo().then(function(ret) { api.refreshServerInfo().then(function(ret) {
// Return to app list with new currentgame // Return to app list with new currentgame