catch rare state loss exception when hitting home button to pop back stack
This commit is contained in:
parent
ad5c9f85c3
commit
9a4109eaa1
|
@ -468,7 +468,11 @@ public class ConversationsActivity extends XmppActivity implements OnConversatio
|
||||||
case android.R.id.home:
|
case android.R.id.home:
|
||||||
FragmentManager fm = getFragmentManager();
|
FragmentManager fm = getFragmentManager();
|
||||||
if (fm.getBackStackEntryCount() > 0) {
|
if (fm.getBackStackEntryCount() > 0) {
|
||||||
fm.popBackStack();
|
try {
|
||||||
|
fm.popBackStack();
|
||||||
|
} catch (IllegalArgumentException e) {
|
||||||
|
Log.w(Config.LOGTAG,"Unable to pop back stack after pressing home button");
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue