2010-05-07 87 views
2

如何糾正這個窗口泄漏的例外。我找不到爲什麼發生。我的LogCat信息:Android中FBConnect泄漏的窗口?

05-07 17:25:05.402: ERROR/WindowManager(13595): Activity com.codecarpet.fbconnect.FBLoginActivity has leaked window [email protected] that was originally added here 
05-07 17:25:05.402: ERROR/WindowManager(13595): android.view.WindowLeaked: Activity com.codecarpet.fbconnect.FBLoginActivity has leaked window [email protected] that was originally added here 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.view.ViewRoot.<init>(ViewRoot.java:214) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:148) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:91) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.view.Window$LocalWindowManager.addView(Window.java:409) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.app.Dialog.show(Dialog.java:238) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.app.ProgressDialog.show(ProgressDialog.java:107) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.app.ProgressDialog.show(ProgressDialog.java:95) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at com.codecarpet.fbconnect.FBProgressDialog.show(FBProgressDialog.java:106) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at com.codecarpet.fbconnect.FBDialog$WebViewClientImpl.onPageStarted(FBDialog.java:508) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.webkit.CallbackProxy.handleMessage(CallbackProxy.java:214) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.os.Handler.dispatchMessage(Handler.java:99) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.os.Looper.loop(Looper.java:123) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at android.app.ActivityThread.main(ActivityThread.java:4203) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at java.lang.reflect.Method.invokeNative(Native Method) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at java.lang.reflect.Method.invoke(Method.java:521) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:791) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) 
05-07 17:25:05.402: ERROR/WindowManager(13595):  at dalvik.system.NativeStart.main(Native Method) 

回答

2

您可能已經離開了一個活動,然後您提出了一個對話框?

3

致電<yourDialog>.dismiss()您的活動的方法。