Android应用程序在后台运行与计时器任务,突然停止任务

时间:2013-05-10 15:52:30

标签: android android-activity scheduled-tasks timertask

我在安卓程序中使用计划任务制作应用程序并在后台运行,但是当我打开其他应用程序并使用我的设备执行某些操作时,我回到我的应用程序检查任务,任务已停止。我有这样的logcat,现在有人在做我错了吗?

05-10 17:55:14.520: W/GpsLocationProvider(149): Unneeded remove listener for uid 1000
05-10 17:55:14.650: W/ActivityManager(149): Scheduling restart of crashed service com.sec.chaton/.push.PushClientService in 5000ms
05-10 17:55:15.740: E/ActivityThread(9192): Failed to find provider info for ownhere.google.settings
05-10 17:55:15.750: E/ActivityThread(9192): Failed to find provider info for ownhere.google.settings
05-10 17:55:15.790: E/ActivityThread(9192): Failed to find provider info for ownhere.google.settings
05-10 17:55:15.790: E/ActivityThread(9192): Failed to find provider info for ownhere.google.settings
05-10 17:55:16.580: W/ActivityManager(149): Scheduling restart of crashed service com.staircase3.opensignal/.library.Background_scan in 5000ms
05-10 17:55:21.680: E/API(9280): 15
05-10 17:55:21.700: E/Background_scan(9280): Tab_Overview.overview_visible=false;
05-10 17:55:34.990: W/ActivityManager(149): startActivity called from non-Activity context; forcing Intent.FLAG_ACTIVITY_NEW_TASK for: Intent { cmp=com.firstwap.celltrack/.MainActivity bnds=[834,488][1264,552] }
05-10 17:55:35.030: W/KeyguardViewMediator(149): verifyUnlock called when not externally disabled
05-10 17:55:35.140: W/ActivityManager(149): Force removing ActivityRecord{414b2478 com.firstwap.celltrack/.MainActivity}: app died, no saved state
05-10 17:55:35.250: W/GpsLocationProvider(149): Duplicate add listener for uid 10012
05-10 17:55:35.350: E/LWUIT(9312): problem with setHasAlpha 
05-10 17:55:35.350: E/LWUIT(9312): java.lang.NoSuchMethodException: setHasAlpha [class java.lang.Boolean]
05-10 17:55:35.350: E/LWUIT(9312):  at java.lang.Class.getConstructorOrMethod(Class.java:460)
05-10 17:55:35.350: E/LWUIT(9312):  at java.lang.Class.getMethod(Class.java:915)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.impl.android.AndroidView.initBitmaps(AndroidView.java:151)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.impl.android.AndroidView.<init>(AndroidView.java:132)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.impl.android.AndroidImplementation$1.run(AndroidImplementation.java:244)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.impl.android.AndroidImplementation$12.run(AndroidImplementation.java:2155)
05-10 17:55:35.350: E/LWUIT(9312):  at android.app.Activity.runOnUiThread(Activity.java:4170)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.impl.android.AndroidImplementation.runOnAndroidUIThreadAndWait(AndroidImplementation.java:2151)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.impl.android.AndroidImplementation.runOnAndroidUIThreadAndWait(AndroidImplementation.java:2144)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.impl.android.AndroidImplementation.initSurface(AndroidImplementation.java:238)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.impl.android.AndroidImplementation.init(AndroidImplementation.java:179)
05-10 17:55:35.350: E/LWUIT(9312):  at com.sun.lwuit.Display.init(Display.java:423)
05-10 17:55:35.350: E/LWUIT(9312):  at com.firstwap.celltrack.MobileCellTrackActivity.onCreate(MobileCellTrackActivity.java:173)
05-10 17:55:35.350: E/LWUIT(9312):  at android.app.Activity.performCreate(Activity.java:4465)
05-10 17:55:35.350: E/LWUIT(9312):  at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1049)
05-10 17:55:35.350: E/LWUIT(9312):  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1920)
05-10 17:55:35.350: E/LWUIT(9312):  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1981)
05-10 17:55:35.350: E/LWUIT(9312):  at android.app.ActivityThread.access$600(ActivityThread.java:123)
05-10 17:55:35.350: E/LWUIT(9312):  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1147)
05-10 17:55:35.350: E/LWUIT(9312):  at android.os.Handler.dispatchMessage(Handler.java:99)
05-10 17:55:35.350: E/LWUIT(9312):  at android.os.Looper.loop(Looper.java:137)
05-10 17:55:35.350: E/LWUIT(9312):  at android.app.ActivityThread.main(ActivityThread.java:4424)
05-10 17:55:35.350: E/LWUIT(9312):  at java.lang.reflect.Method.invokeNative(Native Method)
05-10 17:55:35.350: E/LWUIT(9312):  at java.lang.reflect.Method.invoke(Method.java:511)
05-10 17:55:35.350: E/LWUIT(9312):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
05-10 17:55:35.350: E/LWUIT(9312):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
05-10 17:55:35.350: E/LWUIT(9312):  at dalvik.system.NativeStart.main(Native Method)
05-10 17:55:44.440: W/InputManagerService(149): Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy@4164f0b0
05-10 17:55:47.510: W/InputManagerService(149): Starting input on non-focused client com.android.internal.view.IInputMethodClient$Stub$Proxy@416f80f0 (uid=10012 pid=9312)

1 个答案:

答案 0 :(得分:0)

这是一个崩溃问题(NoSuchMethodException)。

日志:

05-10 17:55:35.350:E / LWUIT(9312):setHasAlpha的问题 05-10 17:55:35.350:E / LWUIT(9312):java.lang.NoSuchMethodException:setHasAlpha [class java.lang.Boolean]