From dc2cd239a1746d3388a38b66ad7eb3fe3a163a83 Mon Sep 17 00:00:00 2001 From: Eric House Date: Tue, 6 Dec 2016 08:15:09 -0800 Subject: [PATCH] wifi: send pending messages on getting connected Each time we get a socket to a peer, try sending all pending wifi direct messages. It's a hack, but trying to send isn't that expensive and the experience is much improved. --- .../XWords4/src/org/eehouse/android/xw4/WiDirService.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/WiDirService.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/WiDirService.java index b12fbd9fc..425648ae8 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/WiDirService.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/WiDirService.java @@ -685,6 +685,10 @@ public class WiDirService extends XWService { DbgUtils.logd( TAG, "storeByAddress(); storing wrap for %s", macAddress ); + + GameUtils.resendAllIf( XWApp.getContext(), + CommsConnType.COMMS_CONN_P2P, + false ); } }