From 0250f42b36fd710abcda14553e83d2356cbcb044 Mon Sep 17 00:00:00 2001 From: Eric House Date: Tue, 25 Nov 2014 07:17:52 -0800 Subject: [PATCH] remove dead invite code --- .../eehouse/android/xw4/BoardDelegate.java | 50 +------------------ 1 file changed, 1 insertion(+), 49 deletions(-) diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/BoardDelegate.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/BoardDelegate.java index 907207f60..53f949402 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/BoardDelegate.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/BoardDelegate.java @@ -855,7 +855,7 @@ public class BoardDelegate extends DelegateBase showConfirmThen( R.string.confirm_undo_last, Action.UNDO_LAST_ACTION ); break; case R.id.board_menu_invite: - inviteForMissing(); + showDialog( DlgID.DLG_INVITE ); break; // small devices only case R.id.board_menu_dict: @@ -1808,54 +1808,6 @@ public class BoardDelegate extends DelegateBase } } // class BoardUtilCtxt - private void inviteForMissing() { - DbgUtils.logf( "BoardDelegate.inviteForMissing()" ); - boolean done = false; - for ( Iterator iter = m_connTypes.iterator(); - !done && iter.hasNext(); ) { - CommsConnType typ = iter.next(); - DbgUtils.logf( "BoardDelegate.inviteForMissing(): got %s", typ.toString() ); - switch( typ ) { - case COMMS_CONN_BT: - nonRelayInvite( Action.BT_PICK_ACTION ); - done = true; - break; - case COMMS_CONN_SMS: - nonRelayInvite( Action.SMS_PICK_ACTION ); - done = true; - break; - case COMMS_CONN_RELAY: - showDialog( DlgID.DLG_INVITE ); - done = true; - break; - } - } - } - - private void nonRelayInvite( final Action action ) - { - DbgUtils.logf( "BoardDelegate.nonRelayInvite()" ); - m_haveInvited = true; - post( new Runnable() { - public void run() { - DbgUtils.showf( m_activity, - getString( R.string.players_miss_fmt, - m_nMissing ) ); - String msg = getString( R.string.invite_msg_fmt, - m_nMissing ); - - if ( Action.BT_PICK_ACTION == action ) { - boolean[] avail = NFCUtils.nfcAvail( m_activity ); - if ( avail[1] ) { - msg += "\n\n" + getString( R.string.invite_if_nfc ); - } - } - - showConfirmThen( msg, R.string.newgame_invite, action ); - } - } ); - } - private void loadGame() { if ( 0 == m_jniGamePtr ) {