From c61191987697a6201b9173771afad28e54ecbde3 Mon Sep 17 00:00:00 2001 From: Eric House Date: Tue, 15 Jan 2019 14:34:50 -0800 Subject: [PATCH] check for moves when come to foreground --- .../app/src/main/java/org/eehouse/android/xw4/XWApp.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/XWApp.java b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/XWApp.java index eaf31a49a..f952afd8b 100644 --- a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/XWApp.java +++ b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/XWApp.java @@ -94,12 +94,16 @@ public class XWApp extends Application implements LifecycleObserver { } @OnLifecycleEvent(ON_ANY) - public void onAny( LifecycleOwner source, Lifecycle.Event event ) + public void onAny( LifecycleOwner source, Lifecycle.Event event ) { Log.d( TAG, "onAny(%s)", event ); switch( event ) { case ON_RESUME: BTService.onAppToForeground( this ); + // Do here what checkForMoves does + if ( null != DBUtils.getRelayIDs( this, null ) ) { + RelayService.timerFired( this ); + } break; case ON_STOP: BTService.onAppToBackground( this );