cleanup from review of changes

This commit is contained in:
Eric House 2017-04-27 07:34:28 -07:00
parent 6caff930e7
commit a1c92b6957
8 changed files with 8 additions and 42 deletions

View file

@ -38,6 +38,7 @@
work anyway.)</li>
<li>Don't open a closed group when moving games to it</li>
<li>Fix occasional crash</li>
<li>Switch from ant to gradle (dev. detail)</li>
</ul>
<p>(The full changelog

View file

@ -83,15 +83,8 @@ public class BoardDelegate extends DelegateBase
NFCUtils.NFCActor {
private static final String TAG = BoardDelegate.class.getSimpleName();
public static final String INTENT_KEY_CHAT = "chat";
private static final int SCREEN_ON_TIME = 10 * 60 * 1000; // 10 mins
private static final String DLG_TITLE = "DLG_TITLE";
private static final String DLG_TITLESTR = "DLG_TITLESTR";
private static final String DLG_BYTES = "DLG_BYTES";
private static final String ROOM = "ROOM";
private static final String PWDNAME = "PWDNAME";
private static final String SAVE_MYSIS = TAG + "/MYSIS";
private Activity m_activity;

View file

@ -50,7 +50,7 @@ public class DBAlert extends XWDialogFragment {
if ( null != obj && !(obj instanceof Serializable) ) {
Log.d( TAG, "OOPS: %s not Serializable",
obj.getClass().getName() );
// Assert.fail();
Assert.assertFalse( BuildConfig.DEBUG );
}
}
}

View file

@ -100,6 +100,7 @@ public class DelegateBase implements DlgClickNotify,
protected void onCreateContextMenu( ContextMenu menu, View view,
ContextMenuInfo menuInfo ) {}
protected boolean onContextItemSelected( MenuItem item ) { return false; }
protected void onStop() {}
protected void onDestroy() {}
protected void onWindowFocusChanged( boolean hasFocus ) {}
protected boolean handleBackPressed() { return false; }
@ -156,16 +157,6 @@ public class DelegateBase implements DlgClickNotify,
XWService.setListener( null );
}
protected void onStop()
{
// Alerts disappear on their own if not in dualpane mode
if ( false
&& m_activity instanceof MainActivity
&& ((MainActivity)m_activity).inDPMode() ) {
DlgDelegate.closeAlerts( m_activity, this );
}
}
protected DelegateBase curThis()
{
DelegateBase result = null;
@ -433,6 +424,7 @@ public class DelegateBase implements DlgClickNotify,
{
DlgID dlgID = alert.getDlgID();
Log.d( TAG, "makeDialog(): not handling %s", dlgID.toString() );
Assert.assertFalse( BuildConfig.DEBUG );
return null;
}

View file

@ -312,7 +312,7 @@ public class DictBrowseDelegate extends DelegateBase
finish();
break;
default:
Assert.assertTrue( !BuildConfig.DEBUG );
Assert.assertFalse( BuildConfig.DEBUG );
}
return handled;
}

View file

@ -929,20 +929,6 @@ public class GamesListDelegate extends ListDelegateBase
.setEnabled( 0 <= m_mySIS.groupSelItem );
}
@Override
protected void prepareDialog( DlgID dlgID, Dialog dialog )
{
Assert.fail();
/*
AlertDialog ad = (AlertDialog)dialog;
switch( dlgID ) {
case CHANGE_GROUP:
ad.getButton( AlertDialog.BUTTON_POSITIVE ).setEnabled( false );
break;
}
*/
}
@Override
protected void init( Bundle savedInstanceState )
{

View file

@ -1,7 +1,6 @@
/* -*- compile-command: "find-and-gradle.sh installXw4Debug"; -*- */
/*
* Copyright 2009-2010 by Eric House (xwords@eehouse.org). All
* rights reserved.
* Copyright 2017 by Eric House (xwords@eehouse.org). All rights reserved.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
@ -21,16 +20,11 @@
package org.eehouse.android.xw4;
import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
public class HostActivity extends XWActivity {
private HostDelegate m_dlgt;
@Override
public void onCreate( Bundle sis ) {
m_dlgt = new HostDelegate( this, sis );
super.onCreate( sis, m_dlgt );
super.onCreate( sis, new HostDelegate( this, sis ) );
}
}

View file

@ -125,7 +125,7 @@ public class SMSInviteDelegate extends InviteDelegate {
if ( Activity.RESULT_CANCELED != resultCode && data != null ) {
switch ( requestCode ) {
case GET_CONTACT:
post ( new Runnable() {
post( new Runnable() {
@Override
public void run() {
addPhoneNumbers( data );