From f63fa6d09de8cfe804f9437575af318ef50aa2ce Mon Sep 17 00:00:00 2001 From: franqueli Date: Tue, 18 Apr 2017 20:52:14 -0400 Subject: [PATCH] Fix Simple Bar Chart Demo, switch use of x and y values (#2365) --- ChartsDemo/Classes/Demos/BarChartViewController.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ChartsDemo/Classes/Demos/BarChartViewController.m b/ChartsDemo/Classes/Demos/BarChartViewController.m index 64d5ee279e..d134a03dcd 100644 --- a/ChartsDemo/Classes/Demos/BarChartViewController.m +++ b/ChartsDemo/Classes/Demos/BarChartViewController.m @@ -138,9 +138,9 @@ - (void)setDataCount:(int)count range:(double)range double mult = (range + 1); double val = (double) (arc4random_uniform(mult)); if (arc4random_uniform(100) < 25) { - [yVals addObject:[[BarChartDataEntry alloc] initWithX:val y:i icon: [UIImage imageNamed:@"icon"]]]; + [yVals addObject:[[BarChartDataEntry alloc] initWithX:i y:val icon: [UIImage imageNamed:@"icon"]]]; } else { - [yVals addObject:[[BarChartDataEntry alloc] initWithX:val y:i]]; + [yVals addObject:[[BarChartDataEntry alloc] initWithX:i y:val]]; } }