##// END OF EJS Templates
update to new legend example
sauimone -
r2172:1aa296db2427
parent child
Show More
@@ -294,8 +294,22 void MainWidget::handleMarkerClicked()
294
294
295 qDebug() << "marker clicked:" << marker;
295 qDebug() << "marker clicked:" << marker;
296
296
297 switch (marker->series()->type())
298 {
299 case QAbstractSeries::SeriesTypePie:
300 {
301 // Series type is pie.
302 // The peer object is QPieSlice
297 QPieSlice* slice = qobject_cast<QPieSlice*> (marker->peerObject());
303 QPieSlice* slice = qobject_cast<QPieSlice*> (marker->peerObject());
298 Q_ASSERT(slice);
304 Q_ASSERT(slice);
299
300 slice->setExploded(!slice->isExploded());
305 slice->setExploded(!slice->isExploded());
306 break;
307 }
308 default:
309 {
310 qDebug() << "Unknown series type";
311 break;
312 }
313 }
314
301 }
315 }
General Comments 0
You need to be logged in to leave comments. Login now