From acafc0a2df934805afcf973847b69c65fb3dc3bf Mon Sep 17 00:00:00 2001 From: Andy2 Date: Fri, 22 Jul 2011 10:55:03 -0700 Subject: [PATCH] remove assert that was there just to prove a fix; use %b in logging. --- .../src/org/eehouse/android/xw4/BoardActivity.java | 8 ++++---- .../XWords4/src/org/eehouse/android/xw4/GameConfig.java | 4 ++-- .../XWords4/src/org/eehouse/android/xw4/GameUtils.java | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/BoardActivity.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/BoardActivity.java index 79e7942c7..ef14c1653 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/BoardActivity.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/BoardActivity.java @@ -352,7 +352,10 @@ public class BoardActivity extends XWActivity { super.onResume(); m_handler = new Handler(); + m_blockingDlgPosted = false; + setKeepScreenOn(); + loadGame(); } @@ -780,7 +783,7 @@ public class BoardActivity extends XWActivity public void setIsServer( boolean isServer ) { - Utils.logf( "setIsServer(%s)", isServer?"true":"false" ); + Utils.logf( "setIsServer(%b)", isServer ); DeviceRole newRole = isServer? DeviceRole.SERVER_ISSERVER : DeviceRole.SERVER_ISCLIENT; if ( newRole != m_gi.serverRole ) { @@ -1050,9 +1053,6 @@ public class BoardActivity extends XWActivity private void loadGame() { - Assert.assertFalse( m_blockingDlgPosted ); // found the problem! - m_blockingDlgPosted = false; - if ( 0 == m_jniGamePtr ) { Assert.assertNull( m_gameLock ); m_gameLock = new GameUtils.GameLock( m_name, true ).lock(); diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/GameConfig.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/GameConfig.java index 38934e3cd..0082e5b6b 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/GameConfig.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/GameConfig.java @@ -919,8 +919,8 @@ public class GameConfig extends XWActivity if ( !m_notNetworkedGame ) { m_car.ip_relay_seeksPublicRoom = m_joinPublicCheck.isChecked(); - Utils.logf( "ip_relay_seeksPublicRoom: %s", - m_car.ip_relay_seeksPublicRoom?"true":"false" ); + Utils.logf( "ip_relay_seeksPublicRoom: %b", + m_car.ip_relay_seeksPublicRoom ); m_car.ip_relay_advertiseRoom = Utils.getChecked( this, R.id.advertise_new_room_check ); if ( m_car.ip_relay_seeksPublicRoom ) { diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/GameUtils.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/GameUtils.java index 16ae51237..0c363c477 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/GameUtils.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/GameUtils.java @@ -831,7 +831,7 @@ public class GameUtils { lock.unlock(); } } - Utils.logf( "feedMessages=>%s", draw?"true":"false" ); + Utils.logf( "feedMessages=>%b", draw ); return draw; }