- Called when nothing has been selected or an “un-select” has been made.
*/
public void onNothingSelected();
}
让你的类实现该接口并设置对 chart 进行监听,即可接受回调。
Simply let your class that should receive the callbacks implement this interface and set it as a listener to the chart:
chart.setOnChartValueSelectedListener(this);
手势回调
监听器 OnChartGestureListener
可以使得 chart 与手势操作进行交互。
public interface OnChartGestureListener {
/**
-
Callbacks when a touch-gesture has started on the chart (ACTION_DOWN)
-
@param me
-
@param lastPerformedGesture
*/
void onChartGestureStart(MotionEvent me, ChartTouchListener.ChartGesture lastPerformedGesture);
/**
-
Callbacks when a touch-gesture has ended on the chart (ACTION_UP, ACTION_CANCEL)
-
@param me