From f562d496ef1b0ea48871885d32743c5d38055d59 Mon Sep 17 00:00:00 2001 From: Franqueli Mendez Date: Sat, 15 Apr 2017 20:24:33 -0400 Subject: [PATCH] Fix Simple Bar Chart Demo, switch use of x and y values --- 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]]; } }