Skip to content

Commit 93563d2

Browse files
adampAndroid (Google) Code Review
authored andcommitted
Merge "Log a warning when action bar view states cannot be restored." into jb-dev
2 parents c8c4ced + fb5f1bc commit 93563d2

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

policy/src/com/android/internal/policy/impl/PhoneWindow.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1630,7 +1630,12 @@ public void restoreHierarchyState(Bundle savedInstanceState) {
16301630
if (mActionBar != null) {
16311631
SparseArray<Parcelable> actionBarStates =
16321632
savedInstanceState.getSparseParcelableArray(ACTION_BAR_TAG);
1633-
mActionBar.restoreHierarchyState(actionBarStates);
1633+
if (actionBarStates != null) {
1634+
mActionBar.restoreHierarchyState(actionBarStates);
1635+
} else {
1636+
Log.w(TAG, "Missing saved instance states for action bar views! " +
1637+
"State will not be restored.");
1638+
}
16341639
}
16351640
}
16361641

0 commit comments

Comments
 (0)