Merge "Prevent ArrayIndexOutOfBoundsException for some invalid sysui_nav_bar values"
This commit is contained in:
@@ -219,6 +219,11 @@ public class NavigationBarInflaterView extends FrameLayout
|
||||
newLayout = getDefaultLayout();
|
||||
}
|
||||
String[] sets = newLayout.split(GRAVITY_SEPARATOR, 3);
|
||||
if (sets.length != 3) {
|
||||
Log.d(TAG, "Invalid layout.");
|
||||
newLayout = getDefaultLayout();
|
||||
sets = newLayout.split(GRAVITY_SEPARATOR, 3);
|
||||
}
|
||||
String[] start = sets[0].split(BUTTON_SEPARATOR);
|
||||
String[] center = sets[1].split(BUTTON_SEPARATOR);
|
||||
String[] end = sets[2].split(BUTTON_SEPARATOR);
|
||||
|
||||
Reference in New Issue
Block a user