private void updateOptionsWithChartEvents(GwtInvientChartsConfig options,
UIDL chartEventUIDL) {
VConsole.log("Enter [updateOptionsWithChartEvents]");
// Chart events
GwtChartEvents chartEvents = GwtChartEvents.create();
if (chartEventUIDL.hasAttribute("addSeries")
&& chartEventUIDL.getBooleanAttribute("addSeries")) {
chartEvents.setAddSeriesEvent(EventCallbacks
.getChartAddSeries(this));
}
if (chartEventUIDL.hasAttribute("click")
&& chartEventUIDL.getBooleanAttribute("click")) {
chartEvents.setClickEvent(EventCallbacks.getChartClick(this));
}
if (chartEventUIDL.hasAttribute("selection")
&& chartEventUIDL.getBooleanAttribute("selection")) {
if (options.getChartOptions().getClientZoom()) {
chartEvents.setSelectionEvent(EventCallbacks
.getClientChartSelection(this));
} else {
chartEvents.setSelectionEvent(EventCallbacks
.getServerChartSelection(this));
}
}
if (options.getChartOptions() == null) {
options.setChartOptions(GwtChartOptions.create());