protected void onSaveInstanceState(Bundle outState) {\r
super.onSaveInstanceState(outState);\r
if (debug) Log.d(TAG, "onSaveInstanceState");\r
+ // It is important to set mIsPausing here, so that\r
+ // the dialog does not get closed on orientation changes.\r
mIsPausing = true;\r
if (debug) Log.d(TAG, "onSaveInstanceState. Pausing: " + mIsPausing);\r
}\r
\r
- \r
+ @Override\r
+ protected void onResume() {\r
+ if (debug) Log.d(TAG, "onResume");\r
+ super.onResume();\r
+ // In case another activity is called, and we are resumed,\r
+ // mIsPausing should be reset to its original state.\r
+ mIsPausing = false;\r
+ }\r
\r
}\r