]> Creatis software - clitk.git/blobdiff - vv/vvToolROIManager.cxx
Replace old gdcm code with vtkGDCMPolyData
[clitk.git] / vv / vvToolROIManager.cxx
index 645941cb4fd3a8555a980c42db12fb3fba0a7486..e1d2e5c534e2f586d45657d3911a14417d6e6641 100644 (file)
@@ -677,6 +677,8 @@ void vvToolROIManager::ChangeColor() {
                 mCurrentROIActor->GetROI()->GetDisplayColor()[1],
                 mCurrentROIActor->GetROI()->GetDisplayColor()[2]);
   QColor c = QColorDialog::getColor(color, this, "Choose the ROI color");
+  if (!c.isValid()) return;// User cancel
+
   mCurrentROIActor->GetROI()->SetDisplayColor(c.redF(), c.greenF(), c.blueF());
   mCurrentROIActor->UpdateColor();