Skip to content

Commit

Permalink
modify fill gradient can't set alpha issue (wuxudong#546)
Browse files Browse the repository at this point in the history
modify fill gradient can't set alpha and orientation top_bottom set error
  • Loading branch information
china-mobile2008 authored and hungtd97 committed Aug 9, 2019
1 parent 7056a37 commit 9c407e3
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ public static void commonLineRadarConfig(LineRadarDataSet dataSet, ReadableMap c

switch (config.getMap("fillGradient").getString("orientation")) {
case "TOP_BOTTOM":
orientation = GradientDrawable.Orientation.BOTTOM_TOP;
orientation = GradientDrawable.Orientation.TOP_BOTTOM;
break;
case "TR_BL":
orientation = GradientDrawable.Orientation.TR_BL;
Expand Down Expand Up @@ -156,7 +156,7 @@ public static void commonLineRadarConfig(LineRadarDataSet dataSet, ReadableMap c
orientation,
colors);
gd.setCornerRadius(0f);

gd.setAlpha(config.getInt("fillAlpha"));
dataSet.setFillDrawable(gd);
} else if (BridgeUtils.validate(config, ReadableType.Number, "fillColor")) {
dataSet.setFillColor(config.getInt("fillColor"));
Expand All @@ -176,4 +176,4 @@ public static void commonLineRadarConfig(LineRadarDataSet dataSet, ReadableMap c
}
}

}
}

0 comments on commit 9c407e3

Please # to comment.