]> Creatis software - clitk.git/blobdiff - vv/vvToolROIManager.cxx
disconnect a signal/slot for ROI contours
[clitk.git] / vv / vvToolROIManager.cxx
index 7a2324b2eecb2d28acd726afbe58a2cd7876a15a..cab86e60553290ae1ec9c5ba39af087bff78721f 100644 (file)
@@ -734,6 +734,7 @@ void vvToolROIManager::AllVisibleROIToggled(int b)
 //------------------------------------------------------------------------------
 void vvToolROIManager::AllVisibleContourROIToggled(int b)
 { 
+  disconnect(mContourCheckBoxShowAll, SIGNAL(stateChanged(int)), this, SLOT(AllVisibleContourROIToggled(int)));
   bool status = false;
   if ((mContourCheckBoxShowAll->checkState() == Qt::Checked) ||
       (mContourCheckBoxShowAll->checkState() == Qt::PartiallyChecked))  status = true;
@@ -746,6 +747,7 @@ void vvToolROIManager::AllVisibleContourROIToggled(int b)
   else  mContourCheckBoxShowAll->setCheckState(Qt::Unchecked);
   mContourCheckBoxShow->setChecked(status);
   mCurrentSlicerManager->Render();
+  connect(mContourCheckBoxShowAll, SIGNAL(stateChanged(int)), this, SLOT(AllVisibleContourROIToggled(int)));
 }
 //------------------------------------------------------------------------------