Search code examples
androidandroid-alertdialogandroid-2.3-gingerbread

Dialog is not visible after activity coming back to foreground


I've a situation in 2.3, and the scenario is.

Listview in an activity, where alert dialog is displayed on list item long press and on simple tap, redirects to another Activity (B)

  • long press on item, alert is displayed properly
  • Close alert
  • normal tap redirects to activity B
  • close Activity B (gets back to Activity A)
  • now long press on list item, now only black translucent blanket is displayed

enter image description here enter image description here

Right side screenshot is only displayed without clear dialog!!

It only happens in 2.3, works just fine in 4.0 >

How can I fix this? any suggestion?


Solution

  • It was fixed by changing TabsActivity to fragmentActivity, because google map was rerendered each time, so placed it in fragment and its fixed