public applySelectionStateToData()

in src/interactivitySelectionService.ts [83:94]


    public applySelectionStateToData(dataPoints: SelectableDataPoint[], hasHighlights?: boolean): boolean {
        if (hasHighlights && this.hasSelection()) {
            this.selectionManager.clear();
        }

        const selectedIds: ISelectionId[] = <ISelectionId[]>this.selectionManager.getSelectionIds();
        for (let dataPoint of dataPoints) {
            dataPoint.selected = this.isDataPointSelected(dataPoint, selectedIds);
        }

        return this.hasSelection();
    }