coreplot酒吧轻拍不工作

我已经从Github上下载了这个代码: https : //github.com/gilthonweapps/CorePlotBarChartExample。如何获得onTap的select吧? 我正在使用下面的代码:

#pragma mark - CPTBarPlotDelegate methods -(void)barPlot:(CPTBarPlot *)plot barWasSelectedAtRecordIndex:(NSUInteger)index { NSLog(@"barWasSelectedAtRecordIndex %d", index); } 

但是这不起作用(它不认识Tap)。请帮助。 预先感谢和新年快乐。

将绘图delegate设置为您的绘图委托对象。 这通常是视图控制器,但不一定是。