diff --git a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/BoardCanvas.java b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/BoardCanvas.java index b3296312a..a80bd8e5f 100644 --- a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/BoardCanvas.java +++ b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/BoardCanvas.java @@ -671,7 +671,7 @@ public class BoardCanvas extends Canvas implements DrawCtx { final int CLIP_SAVE_FLAG = 0x02; try { sSaveMethod.invoke( this, CLIP_SAVE_FLAG ); - Log.d( TAG, "saveImpl() worked" ); + // Log.d( TAG, "saveImpl() worked" ); } catch ( java.lang.reflect.InvocationTargetException | IllegalAccessException ex ) { Log.e( TAG, "%s", ex ); diff --git a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/BoardDelegate.java b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/BoardDelegate.java index 155274d96..0f76ea5a4 100644 --- a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/BoardDelegate.java +++ b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/BoardDelegate.java @@ -1457,7 +1457,7 @@ public class BoardDelegate extends DelegateBase @Override public void tpmCountChanged( final int newCount ) { - Log.d( TAG, "tpmCountChanged(%d)", newCount ); + Log.d( TAG, "tpmCountChanged(newCount=%d)", newCount ); ConnStatusHandler.updateMoveCount( m_activity, newCount ); final GameOverAlert goAlert = mGameOverAlert; diff --git a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/InviteChoicesAlert.java b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/InviteChoicesAlert.java index 27c92c61f..76427f89a 100644 --- a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/InviteChoicesAlert.java +++ b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/InviteChoicesAlert.java @@ -54,15 +54,18 @@ public class InviteChoicesAlert extends DlgDelegateAlert return result; } - public static void dismissAny() + public static boolean dismissAny() { + boolean dismissed = false; WeakReference ref = sSelf; if ( null != ref ) { InviteChoicesAlert self = ref.get(); if ( null != self ) { self.dismiss(); + dismissed = true; } } + return dismissed; } public InviteChoicesAlert() {} diff --git a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/InvitesNeededAlert.java b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/InvitesNeededAlert.java index dd197d411..ae8058837 100644 --- a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/InvitesNeededAlert.java +++ b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/InvitesNeededAlert.java @@ -75,8 +75,7 @@ class InvitesNeededAlert { { Log.d( TAG, "dismiss()" ); DbgUtils.assertOnUIThread(); - if ( null != mSelf ) { - mSelf.close(); + if ( null != mSelf && mSelf.close() ) { mSelf = null; } } @@ -113,17 +112,19 @@ class InvitesNeededAlert { void onInfoClicked(); } - private void close() + private boolean close() { + boolean dismissed = false; DbgUtils.assertOnUIThread(); if ( null != mAlert ) { - InviteChoicesAlert.dismissAny(); + dismissed = InviteChoicesAlert.dismissAny(); try { mAlert.dismiss(); // I've seen this throw a NPE inside } catch ( Exception ex ) { Log.ex( TAG, ex ); } } + return dismissed; } private InvitesNeededAlert( DelegateBase delegate, State state )