private void setupPieChartSelection(PiePlot plot, Chart chart) {
if (((PieChartView) chart.getChartView()).getSelectedSector() != null) {
final PieSectorInfo info = ((PieChartView) chart.getChartView()).getSelectedSector();
final ChartSelection selection = chart.getChartSelection();
final LineStyle lineStyle = selection.getLineStyle();
Paint outlinePaint = lineStyle.getColor() != null
? lineStyle.getColor()
: Color.WHITE;
final Stroke outlineStroke = lineStyle.getStroke();
final Paint selectionPaint = selection.getFillPaint();
plot.setSectionOutlinePaint(info.getIndex(), outlinePaint);
if (outlineStroke != null) {
plot.setSectionOutlineStroke(info.getIndex(), outlineStroke);