summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Lee <anwlee@google.com>2015-10-21 14:00:31 -0700
committerAndrew Lee <anwlee@google.com>2015-10-21 14:00:31 -0700
commit3151f53974425c6b07c12e94eb4e6f4ab72818bc (patch)
tree205bda94ab4b698f9e62d10f56fe7ad3ba6e80a0
parentd625d28ec6cf22c128d0ef0b8e64a9fff4b64aec (diff)
Prevent fragment rotation crashes.
Also, causes right fragment to retain after rotation and recreation. Bug: 25154818 Bug: 24910704 Change-Id: Icafbc7ba6f3ad877c2d28d92e510b9afbd822b65
-rw-r--r--src/com/android/dialer/filterednumber/ManageBlockedNumbersActivity.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/com/android/dialer/filterednumber/ManageBlockedNumbersActivity.java b/src/com/android/dialer/filterednumber/ManageBlockedNumbersActivity.java
index 581ff98b5..f785cf77a 100644
--- a/src/com/android/dialer/filterednumber/ManageBlockedNumbersActivity.java
+++ b/src/com/android/dialer/filterednumber/ManageBlockedNumbersActivity.java
@@ -49,7 +49,10 @@ public class ManageBlockedNumbersActivity extends AppCompatActivity
super.onCreate(savedInstanceState);
setContentView(R.layout.blocked_numbers_activity);
- showManagementUi();
+ // If savedInstanceState != null, the Activity will automatically restore the last fragment.
+ if (savedInstanceState == null) {
+ showManagementUi();
+ }
}
public void showManagementUi() {