Rect portraitMargins = new Rect(0, 0, 0, 0);
Rect landscapeMargins = new Rect(0, 0, 0, 0);
if (bundle.containsKey(paramPortraitMargins)) {
if (bundle.getSerializable(paramPortraitMargins) != null
&& bundle.getSerializable(paramPortraitMargins) instanceof List) {
<BUG>List<Object> list = (List<Object>) bundle.getSerializable(paramPortraitMargins);
if (list.size() == 4 && UIParamParser.checkClassOfListObjects(list, Integer.class)) {

portraitMargins = new Rect((Integer) list.get(0), (Integer) list.get(1),
(Integer) list.get(2), (Integer) list.get(3));
}</BUG>
} else if (bundle.getString(paramPortraitMargins) != null) {

Rect portraitMargins = new Rect(0, 0, 0, 0);
Rect landscapeMargins = new Rect(0, 0, 0, 0);
if (bundle.containsKey(paramPortraitMargins)) {
if (bundle.getSerializable(paramPortraitMargins) != null
&& bundle.getSerializable(paramPortraitMargins) instanceof List) {
List<Object> list = (List<Object>) bundle.getSerializable(paramPortraitMargins);
if (list.size() == 4 &&
(UIParamParser.checkClassOfListObjects(list, Integer.class) ||
UIParamParser.checkClassOfListObjects(list, String.class))) {
portraitMargins = new Rect(UIParamParser.getDp(list.get(0)), UIParamParser.getDp(list.get(1)),
UIParamParser.getDp(list.get(2)), UIParamParser.getDp(list.get(3)));
}
} else if (bundle.getString(paramPortraitMargins) != null) {
