2
2
3
3
import android .os .Handler ;
4
4
import android .os .Looper ;
5
- import android .util .Log ;
6
5
7
6
import com .shizhefei .mvc .IAsyncDataSource ;
8
7
import com .shizhefei .mvc .IDataSource ;
@@ -137,11 +136,6 @@ protected DATA doInBackground(Object... params) {
137
136
try {
138
137
return executeImp (responseSender );
139
138
} catch (Exception e ) {
140
- if (e instanceof InterruptedException ) {
141
- Log .d ("TaskHelper" , realTask .toString () + e );
142
- } else {
143
- e .printStackTrace ();
144
- }
145
139
responseSender .sendError (e );
146
140
}
147
141
return null ;
@@ -394,11 +388,11 @@ public boolean isRunning() {
394
388
private void onPreExecute () {
395
389
if (Looper .myLooper () != Looper .getMainLooper ()) {
396
390
handler .post (new Runnable () {
397
- @ Override
398
- public void run () {
399
- onPreExecuteMainThread ();
400
- }
401
- });
391
+ @ Override
392
+ public void run () {
393
+ onPreExecuteMainThread ();
394
+ }
395
+ });
402
396
} else {
403
397
onPreExecuteMainThread ();
404
398
}
@@ -420,11 +414,11 @@ public void run() {
420
414
private void onPostExecute (final Code code , final Exception exception , final DATA data ) {
421
415
if (Looper .myLooper () != Looper .getMainLooper ()) {
422
416
handler .post (new Runnable () {
423
- @ Override
424
- public void run () {
425
- onPostExecuteMainThread (code , exception , data );
426
- }
427
- });
417
+ @ Override
418
+ public void run () {
419
+ onPostExecuteMainThread (code , exception , data );
420
+ }
421
+ });
428
422
} else {
429
423
onPostExecuteMainThread (code , exception , data );
430
424
}
0 commit comments