Manually closing Activity leaves transparent window
I have a problem and I found nothing in my searches that's solving it.
My activity should close, when the user presses the Ok-/Cancel-Button
of a created AlertDialog
.
When the activity is closing, there is a transparent overlay remaining. How can I let it disappear?
I t开发者_运维百科ried it with System.exit(0) and finish()
, both with the same result.
How can I close the activity without any remains?
Thanks very much for you help!
It sounds like you're closing the activity and the dialog is being left behind.
Call dialog.dismiss()
or dialog.cancel()
on the DialogInterface.OnClickListener
and then call finish()
and see what happens. But really, we need some code.
精彩评论