mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-28 07:58:08 +01:00
remove posts to noSuchGame()
Looks like ack() does all we need, with new param
This commit is contained in:
parent
67cf8518de
commit
c9f1863c1e
1 changed files with 0 additions and 24 deletions
|
@ -562,34 +562,11 @@ public class MQTTUtils extends Thread
|
||||||
clearInstance( this );
|
clearInstance( this );
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void postNoSuchGame( final Context context, final int gameID )
|
|
||||||
{
|
|
||||||
// Run in thread in case we're called on main thread
|
|
||||||
new Thread( new Runnable() {
|
|
||||||
@Override
|
|
||||||
public void run() {
|
|
||||||
JSONObject params = new JSONObject();
|
|
||||||
try {
|
|
||||||
String devid = XwJNI.dvc_getMQTTDevID();
|
|
||||||
params.put( "devid", devid );
|
|
||||||
params.put( "gameid", gameID );
|
|
||||||
HttpsURLConnection conn
|
|
||||||
= NetUtils.makeHttpsMQTTConn( context, "noSuchGame" );
|
|
||||||
/*(void*)*/NetUtils.runConn( conn, params, true );
|
|
||||||
} catch ( JSONException jex ) {
|
|
||||||
Log.e( TAG, "notifyNotHere() ex: %s", jex );
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} ).start();
|
|
||||||
}
|
|
||||||
|
|
||||||
private static void notifyNotHere( Context context, String addressee,
|
private static void notifyNotHere( Context context, String addressee,
|
||||||
int gameID )
|
int gameID )
|
||||||
{
|
{
|
||||||
TopicsAndPackets tap = XwJNI.dvc_makeMQTTNoSuchGames( addressee, gameID );
|
TopicsAndPackets tap = XwJNI.dvc_makeMQTTNoSuchGames( addressee, gameID );
|
||||||
addToSendQueue( context, tap );
|
addToSendQueue( context, tap );
|
||||||
|
|
||||||
postNoSuchGame( context, gameID );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static int send( Context context, TopicsAndPackets tap )
|
public static int send( Context context, TopicsAndPackets tap )
|
||||||
|
@ -797,7 +774,6 @@ public class MQTTUtils extends Thread
|
||||||
new MQTTServiceHelper( context, from )
|
new MQTTServiceHelper( context, from )
|
||||||
.postEvent( MultiService.MultiEvent.MESSAGE_NOGAME, gameID,
|
.postEvent( MultiService.MultiEvent.MESSAGE_NOGAME, gameID,
|
||||||
expl );
|
expl );
|
||||||
postNoSuchGame( context, gameID );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void fcmConfirmed( Context context, boolean working )
|
public static void fcmConfirmed( Context context, boolean working )
|
||||||
|
|
Loading…
Add table
Reference in a new issue