opt
This commit is contained in:
@@ -193,13 +193,14 @@ public class MogoServiceProvider implements IMogoModuleProvider,
|
||||
@Override
|
||||
public void onSuccess() {
|
||||
mLoopRequest = false;
|
||||
Logger.d(TAG, "request Success.");
|
||||
Logger.d( TAG, "request Success." );
|
||||
invokeAutoRefreshStrategy();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFail() {
|
||||
if ( mLoopRequest ) {
|
||||
Logger.d( TAG, "onFail and loop" );
|
||||
mHandler.sendEmptyMessageDelayed( ServiceConst.MSG_LOOP_REQUEST, ServiceConst.LOOP_INTERVAL );
|
||||
} else {
|
||||
invokeAutoRefreshStrategy();
|
||||
@@ -504,8 +505,6 @@ public class MogoServiceProvider implements IMogoModuleProvider,
|
||||
return;
|
||||
}
|
||||
|
||||
Logger.d( TAG, "onLocationChanged = %s", location );
|
||||
|
||||
// 自动刷新触发
|
||||
final MogoLatLng point = new MogoLatLng( location.getLatitude(), location.getLongitude() );
|
||||
if ( mLastAutoRefreshLocation == null ) {
|
||||
|
||||
@@ -77,6 +77,14 @@ public class RefreshModel {
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError( Throwable e ) {
|
||||
super.onError( e );
|
||||
if (callback != null) {
|
||||
callback.onFail();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(String message, int code) {
|
||||
super.onError(message, code);
|
||||
|
||||
Reference in New Issue
Block a user