Fix little issue in PNLineChart,m
the delegate(userClickedOnLinePoint: lineIndex:) in method(touchPoint: withEvent:) is never called,because the point p1 is not in each line path.So,when touch the line path,nothing happens(the delegate is invalid).
Showing
1 changed file
with
4 additions
and
0 deletions
| @@ -435,9 +435,13 @@ | @@ -435,9 +435,13 @@ | ||
| 435 | 435 | ||
| 436 | if ( i != 0 ) { | 436 | if ( i != 0 ) { |
| 437 | [progressline addLineToPoint:CGPointMake(x, y)]; | 437 | [progressline addLineToPoint:CGPointMake(x, y)]; |
| 438 | + [lineStartEndPointsArray addObject:[NSValue valueWithCGPoint:CGPointMake(x, y)]]; | ||
| 438 | } | 439 | } |
| 439 | 440 | ||
| 440 | [progressline moveToPoint:CGPointMake(x, y)]; | 441 | [progressline moveToPoint:CGPointMake(x, y)]; |
| 442 | + if(i != chartData.itemCount - 1){ | ||
| 443 | + [lineStartEndPointsArray addObject:[NSValue valueWithCGPoint:CGPointMake(x, y)]]; | ||
| 444 | + } | ||
| 441 | } | 445 | } |
| 442 | 446 | ||
| 443 | [linePointsArray addObject:[NSValue valueWithCGPoint:CGPointMake(x, y)]]; | 447 | [linePointsArray addObject:[NSValue valueWithCGPoint:CGPointMake(x, y)]]; |
-
Please register or login to post a comment