check for moves when come to foreground

This commit is contained in:
Eric House 2019-01-15 14:34:50 -08:00
parent e61d7a5629
commit c611919876

View file

@ -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 );