Exemplo n.º 1
0
 @ReactProp(name = ViewProps.BORDER_WIDTH, defaultFloat = CSSConstants.UNDEFINED)
 public void setBorderWidth(ReactViewGroup view, float width) {
   if (!CSSConstants.isUndefined(width)) {
     width = PixelUtil.toPixelFromDIP(width);
   }
   view.setBorderWidth(Spacing.ALL, width);
 }
Exemplo n.º 2
0
 @ReactPropGroup(
     names = {
       ViewProps.BORDER_WIDTH,
       ViewProps.BORDER_LEFT_WIDTH,
       ViewProps.BORDER_RIGHT_WIDTH,
       ViewProps.BORDER_TOP_WIDTH,
       ViewProps.BORDER_BOTTOM_WIDTH,
     },
     defaultFloat = CSSConstants.UNDEFINED)
 public void setBorderWidth(ReactViewGroup view, int index, float width) {
   if (!CSSConstants.isUndefined(width)) {
     width = PixelUtil.toPixelFromDIP(width);
   }
   view.setBorderWidth(SPACING_TYPES[index], width);
 }