mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-15 15:41:24 +01:00
remove dead invite code
This commit is contained in:
parent
8974407a67
commit
0250f42b36
1 changed files with 1 additions and 49 deletions
|
@ -855,7 +855,7 @@ public class BoardDelegate extends DelegateBase
|
||||||
showConfirmThen( R.string.confirm_undo_last, Action.UNDO_LAST_ACTION );
|
showConfirmThen( R.string.confirm_undo_last, Action.UNDO_LAST_ACTION );
|
||||||
break;
|
break;
|
||||||
case R.id.board_menu_invite:
|
case R.id.board_menu_invite:
|
||||||
inviteForMissing();
|
showDialog( DlgID.DLG_INVITE );
|
||||||
break;
|
break;
|
||||||
// small devices only
|
// small devices only
|
||||||
case R.id.board_menu_dict:
|
case R.id.board_menu_dict:
|
||||||
|
@ -1808,54 +1808,6 @@ public class BoardDelegate extends DelegateBase
|
||||||
}
|
}
|
||||||
} // class BoardUtilCtxt
|
} // class BoardUtilCtxt
|
||||||
|
|
||||||
private void inviteForMissing() {
|
|
||||||
DbgUtils.logf( "BoardDelegate.inviteForMissing()" );
|
|
||||||
boolean done = false;
|
|
||||||
for ( Iterator<CommsConnType> 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()
|
private void loadGame()
|
||||||
{
|
{
|
||||||
if ( 0 == m_jniGamePtr ) {
|
if ( 0 == m_jniGamePtr ) {
|
||||||
|
|
Loading…
Reference in a new issue