Skip to content

Commit

Permalink
Minor bugfixes
Browse files Browse the repository at this point in the history
  • Loading branch information
prithsharma committed Jun 25, 2016
1 parent d03122d commit f71d38f
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,15 +88,15 @@ public void setData(BarChart chart,ReadableMap rm){
* - duration or durationX/durationY in case of animateXY
* - support for easeFunction yet to be given
*/
if (config.hasKey("animateX")) {
chart.animateX(config.getMap(animateX).getInt(duration));
} else if (config.hasKey("animateY")) {
chart.animateY(config.getMap(animateY).getInt(duration));
} else if (config.hasKey("animateXY")) {
ReadableMap animationConfig = config.getMap(animateXY);
if (rm.hasKey("animateX")) {
chart.animateX(rm.getMap("animateX").getInt("duration"));
} else if (rm.hasKey("animateY")) {
chart.animateY(rm.getMap("animateY").getInt("duration"));
} else if (rm.hasKey("animateXY")) {
ReadableMap animationConfig = rm.getMap("animateXY");
chart.animateXY(
animationConfig.getInt(durationX),
animationConfig.getInt(durationY)
animationConfig.getInt("durationX"),
animationConfig.getInt("durationY")
);
} else {
chart.invalidate();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,15 +114,15 @@ public void setData(LineChart chart,ReadableMap rm){
* - duration or durationX/durationY in case of animateXY
* - support for easeFunction yet to be given
*/
if (config.hasKey("animateX")) {
chart.animateX(config.getMap(animateX).getInt(duration));
} else if (config.hasKey("animateY")) {
chart.animateY(config.getMap(animateY).getInt(duration));
} else if (config.hasKey("animateXY")) {
ReadableMap animationConfig = config.getMap(animateXY);
if (rm.hasKey("animateX")) {
chart.animateX(rm.getMap("animateX").getInt("duration"));
} else if (rm.hasKey("animateY")) {
chart.animateY(rm.getMap("animateY").getInt("duration"));
} else if (rm.hasKey("animateXY")) {
ReadableMap animationConfig = rm.getMap("animateXY");
chart.animateXY(
animationConfig.getInt(durationX),
animationConfig.getInt(durationY)
animationConfig.getInt("durationX"),
animationConfig.getInt("durationY")
);
} else {
chart.invalidate();
Expand Down

0 comments on commit f71d38f

Please sign in to comment.