don't show webui url when game not using mqtt (debug only)

This commit is contained in:
Eric House 2024-01-20 15:54:34 -08:00
parent e3310ff895
commit d543b58150
3 changed files with 6 additions and 2 deletions

View file

@ -1510,6 +1510,10 @@ public class BoardDelegate extends DelegateBase
PopupMenu popup = new PopupMenu( m_activity, view );
popup.getMenuInflater().inflate( R.menu.netstat, popup.getMenu() );
if ( ! m_connTypes.contains(CommsConnType.COMMS_CONN_MQTT) ) {
popup.getMenu().removeItem( R.id.netstat_menu_traffic );
}
popup.setOnMenuItemClickListener( new PopupMenu
.OnMenuItemClickListener() {
@Override

View file

@ -1248,7 +1248,7 @@ public class GameUtils {
} catch ( GameLock.GameLockedException gle ) {
DbgUtils.toastNoLock( TAG, context, rowid,
"feedMessage(): dropping message"
+ " for %d", rowid );
+ " for rowid %d", rowid );
}
}
return draw;

View file

@ -81,7 +81,7 @@ public class NetUtils {
String host = XWPrefs.getPrefsString( context, R.string.key_mqtt_host );
String myID = XwJNI.dvc_getMQTTDevID();
// Use the route that doesn't require login
String url = String.format( "https://%s/xw4/ui/gameinfo?gameid=%d&devid=%s",
String url = String.format( "https://%s/xw4/ui/gameinfo?gid16=%X&devid=%s",
host, gameID, myID );
return url;
}