我正在实现一个小型的Android应用程序,它正确地在小分辨率设备和模拟器中正确启动。但我无法在大分辨率(平板电脑)模拟器中启动相同的应用程序。我正在低于例外。
06-06 05:30:56.958: W/ActivityManager(295): Unable to start service Intent { act=com.android.email.ACCOUNT_INTENT } U=0: not found
06-06 05:30:56.958: D/ExchangeService(771): !!! Email application not found; stopping self
06-06 05:30:57.009: W/ActivityManager(295): Unable to start service Intent { act=com.android.email.ACCOUNT_INTENT } U=0: not found
06-06 05:30:57.102: E/ActivityThread(771): Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d1c0b0 that was originally bound here
06-06 05:30:57.102: E/ActivityThread(771): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d1c0b0 that was originally bound here
06-06 05:30:57.102: E/ActivityThread(771): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
06-06 05:30:57.102: E/ActivityThread(771): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
06-06 05:30:57.102: E/ActivityThread(771): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
06-06 05:30:57.102: E/ActivityThread(771): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
06-06 05:30:57.102: E/ActivityThread(771): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
06-06 05:30:57.102: E/ActivityThread(771): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
06-06 05:30:57.102: E/ActivityThread(771): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
06-06 05:30:57.102: E/ActivityThread(771): at com.android.emailcommon.service.ServiceProxy.test(ServiceProxy.java:191)
06-06 05:30:57.102: E/ActivityThread(771): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1850)
06-06 05:30:57.102: E/ActivityThread(771): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
06-06 05:30:57.102: E/ActivityThread(771): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
06-06 05:30:57.102: E/ActivityThread(771): at android.os.AsyncTask$2.call(AsyncTask.java:287)
06-06 05:30:57.102: E/ActivityThread(771): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
06-06 05:30:57.102: E/ActivityThread(771): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
06-06 05:30:57.102: E/ActivityThread(771): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
06-06 05:30:57.102: E/ActivityThread(771): at java.lang.Thread.run(Thread.java:856)
06-06 05:30:57.123: E/StrictMode(771): null
06-06 05:30:57.123: E/StrictMode(771): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d1c0b0 that was originally bound here
06-06 05:30:57.123: E/StrictMode(771): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
06-06 05:30:57.123: E/StrictMode(771): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
06-06 05:30:57.123: E/StrictMode(771): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
06-06 05:30:57.123: E/StrictMode(771): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
06-06 05:30:57.123: E/StrictMode(771): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
06-06 05:30:57.123: E/StrictMode(771): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
06-06 05:30:57.123: E/StrictMode(771): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
06-06 05:30:57.123: E/StrictMode(771): at com.android.emailcommon.service.ServiceProxy.test(ServiceProxy.java:191)
06-06 05:30:57.123: E/StrictMode(771): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1850)
06-06 05:30:57.123: E/StrictMode(771): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
06-06 05:30:57.123: E/StrictMode(771): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
06-06 05:30:57.123: E/StrictMode(771): at android.os.AsyncTask$2.call(AsyncTask.java:287)
06-06 05:30:57.123: E/StrictMode(771): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
06-06 05:30:57.123: E/StrictMode(771): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
06-06 05:30:57.123: E/StrictMode(771): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
06-06 05:30:57.123: E/StrictMode(771): at java.lang.Thread.run(Thread.java:856)
06-06 05:30:57.168: W/ActivityManager(295): Unbind failed: could not find connection for android.os.BinderProxy@4104c798
06-06 05:30:57.228: E/ActivityThread(771): Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d1c478 that was originally bound here
06-06 05:30:57.228: E/ActivityThread(771): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d1c478 that was originally bound here
06-06 05:30:57.228: E/ActivityThread(771): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
06-06 05:30:57.228: E/ActivityThread(771): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
06-06 05:30:57.228: E/ActivityThread(771): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
06-06 05:30:57.228: E/ActivityThread(771): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
06-06 05:30:57.228: E/ActivityThread(771): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
06-06 05:30:57.228: E/ActivityThread(771): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
06-06 05:30:57.228: E/ActivityThread(771): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
06-06 05:30:57.228: E/ActivityThread(771): at com.android.emailcommon.service.AccountServiceProxy.getDeviceId(AccountServiceProxy.java:116)
06-06 05:30:57.228: E/ActivityThread(771): at com.android.exchange.ExchangeService.getDeviceId(ExchangeService.java:1249)
06-06 05:30:57.228: E/ActivityThread(771): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1856)
06-06 05:30:57.228: E/ActivityThread(771): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
06-06 05:30:57.228: E/ActivityThread(771): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
06-06 05:30:57.228: E/ActivityThread(771): at android.os.AsyncTask$2.call(AsyncTask.java:287)
06-06 05:30:57.228: E/ActivityThread(771): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
06-06 05:30:57.228: E/ActivityThread(771): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
06-06 05:30:57.228: E/ActivityThread(771): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
06-06 05:30:57.228: E/ActivityThread(771): at java.lang.Thread.run(Thread.java:856)
06-06 05:30:57.308: E/StrictMode(771): null
06-06 05:30:57.308: E/StrictMode(771): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d1c478 that was originally bound here
06-06 05:30:57.308: E/StrictMode(771): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
06-06 05:30:57.308: E/StrictMode(771): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
06-06 05:30:57.308: E/StrictMode(771): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
06-06 05:30:57.308: E/StrictMode(771): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
06-06 05:30:57.308: E/StrictMode(771): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
06-06 05:30:57.308: E/StrictMode(771): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
06-06 05:30:57.308: E/StrictMode(771): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
06-06 05:30:57.308: E/StrictMode(771): at com.android.emailcommon.service.AccountServiceProxy.getDeviceId(AccountServiceProxy.java:116)
06-06 05:30:57.308: E/StrictMode(771): at com.android.exchange.ExchangeService.getDeviceId(ExchangeService.java:1249)
06-06 05:30:57.308: E/StrictMode(771): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1856)
06-06 05:30:57.308: E/StrictMode(771): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
06-06 05:30:57.308: E/StrictMode(771): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
06-06 05:30:57.308: E/StrictMode(771): at android.os.AsyncTask$2.call(AsyncTask.java:287)
06-06 05:30:57.308: E/StrictMode(771): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
06-06 05:30:57.308: E/StrictMode(771): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
06-06 05:30:57.308: E/StrictMode(771): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
06-06 05:30:57.308: E/StrictMode(771): at java.lang.Thread.run(Thread.java:856)
请帮帮我
答案 0 :(得分:0)
在清单文件的活动中添加以下行:
android:configChanges="screenSize|keyboardHidden|orientation"
答案 1 :(得分:0)
您的服务停止后,您正在做一些事情。
在unbindService(mConnection);
方法中添加onStop()
。代码将开始正常工作
我不这么认为这与屏幕分辨率无关。