Loading tools/layoutlib/bridge/src/android/content/res/BridgeTypedArray.java +2 −5 Original line number Diff line number Diff line Loading @@ -239,15 +239,12 @@ public final class BridgeTypedArray extends TypedArray { public int getInt(int index, int defValue) { String s = getString(index); try { if (s != null) { return convertValueToInt(s, defValue); } } catch (NumberFormatException e) { Bridge.getLog().warning(LayoutLog.TAG_RESOURCES_FORMAT, String.format("\"%1$s\" in attribute \"%2$s\" is not a valid integer", s, mNames[index]), null); return defValue; } return defValue; } Loading Loading @@ -949,7 +946,7 @@ public final class BridgeTypedArray extends TypedArray { * "XXXXXXXX" > 80000000. */ private static int convertValueToInt(@Nullable String charSeq, int defValue) { if (null == charSeq) if (null == charSeq || charSeq.isEmpty()) return defValue; int sign = 1; Loading tools/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/Layout.java +1 −0 Original line number Diff line number Diff line Loading @@ -131,6 +131,7 @@ class Layout extends RelativeLayout { HardwareConfig hwConfig = getParams().getHardwareConfig(); Density density = hwConfig.getDensity(); boolean isRtl = Bridge.isLocaleRtl(getParams().getLocale()); setLayoutDirection(isRtl? LAYOUT_DIRECTION_RTL : LAYOUT_DIRECTION_LTR); NavigationBar navBar = null; if (mBuilder.hasNavBar()) { Loading Loading
tools/layoutlib/bridge/src/android/content/res/BridgeTypedArray.java +2 −5 Original line number Diff line number Diff line Loading @@ -239,15 +239,12 @@ public final class BridgeTypedArray extends TypedArray { public int getInt(int index, int defValue) { String s = getString(index); try { if (s != null) { return convertValueToInt(s, defValue); } } catch (NumberFormatException e) { Bridge.getLog().warning(LayoutLog.TAG_RESOURCES_FORMAT, String.format("\"%1$s\" in attribute \"%2$s\" is not a valid integer", s, mNames[index]), null); return defValue; } return defValue; } Loading Loading @@ -949,7 +946,7 @@ public final class BridgeTypedArray extends TypedArray { * "XXXXXXXX" > 80000000. */ private static int convertValueToInt(@Nullable String charSeq, int defValue) { if (null == charSeq) if (null == charSeq || charSeq.isEmpty()) return defValue; int sign = 1; Loading
tools/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/Layout.java +1 −0 Original line number Diff line number Diff line Loading @@ -131,6 +131,7 @@ class Layout extends RelativeLayout { HardwareConfig hwConfig = getParams().getHardwareConfig(); Density density = hwConfig.getDensity(); boolean isRtl = Bridge.isLocaleRtl(getParams().getLocale()); setLayoutDirection(isRtl? LAYOUT_DIRECTION_RTL : LAYOUT_DIRECTION_LTR); NavigationBar navBar = null; if (mBuilder.hasNavBar()) { Loading