]> Creatis software - creaContours.git/blobdiff - lib/Interface_Icons_NDimensions/interfMainPanel.cxx
no message
[creaContours.git] / lib / Interface_Icons_NDimensions / interfMainPanel.cxx
index 6a308294bee53d3d935666895bc01374bb701323..40456bf8f691ba68fffbc1038ab59ebedf7a9c90 100644 (file)
@@ -587,7 +587,7 @@ void interfMainPanel::onInformationPressed(){
                infoPanelMask->SetSizer(flexsizer, true);
                infoPanelMask->SetAutoLayout( true );   
                //configPanel->SetEventHandler(this->contourevent);
-               wxPanel *panel = wxContourMainFrame::getInstance()->getThresholdImageViewPanel( infoPanelMask );                                
+               wxPanel *panel = wxContourMainFrame::getInstance()->getMaskImageViewPanel( infoPanelMask );                             
                wxStaticText* stattext = new wxStaticText(infoPanelMask, -1, wxString(_T("   Mask segmentation    ")), wxDefaultPosition,
                                                                                                  wxDefaultSize, wxALIGN_CENTRE|wxBORDER_SIMPLE|wxFULL_REPAINT_ON_RESIZE, wxString(_T("")));
                
@@ -721,63 +721,39 @@ void interfMainPanel::onMirrorChangeWidth(int width)
 }
 
 
-void interfMainPanel::onThreshold()
-{
-       wxContourMainFrame::getInstance()->onThreshold();
-}
-
-void interfMainPanel::onThresholdChange()
-{
-       wxContourMainFrame::getInstance()->onThresholdChange();
-}
-
-void interfMainPanel::onThresholdInstantChange(double range[])
-{
-       panelThreshold->onThresholdInstantChange(range);
-}
-
-void interfMainPanel::onThresholdInterpolation(bool interpolate)
-{
-       wxContourMainFrame::getInstance()->onThresholdInterpolation(interpolate);
-}
-
-void interfMainPanel::onThresholdChangeOpacity (int opacity)
-{
-       wxContourMainFrame::getInstance()->onThresholdChangeOpacity(opacity);
-}
-
-void interfMainPanel::onThresholdRemove()
-{
-       wxContourMainFrame::getInstance()->onThresholdRemove();
-}
 
+//EED01
 void interfMainPanel::onThresholdPressed()
 {
-    if(thresholdPanel==NULL)
-       {
-
-               thresholdPanel = new wxPanel(interfMainPanel::getInstance()->getInfoPanel(), -1, wxDefaultPosition, wxDefaultSize, wxBORDER_STATIC, wxString(_T("")));
+       
+       // Threshold view control panel
+       if(thresholdPanel == NULL){
+               thresholdPanel = new wxPanel(interfMainPanel::getInstance()->getInfoPanel(), -1, wxDefaultPosition, wxDefaultSize, wxNO_BORDER, wxString(_T("")));
                wxFlexGridSizer* flexsizer = new wxFlexGridSizer(1);    
                thresholdPanel->SetSizer(flexsizer, true);
                thresholdPanel->SetAutoLayout( true );  
-               panelThreshold = new interfThresholdPanel(thresholdPanel);
-       
-               wxStaticText* stattext = new wxStaticText(thresholdPanel, -1, wxString(_T("   Threshold Tool   ")), wxDefaultPosition,
-                       wxDefaultSize, wxALIGN_CENTRE|wxBORDER_SIMPLE|wxFULL_REPAINT_ON_RESIZE, wxString(_T("")));
-
+               //configPanel->SetEventHandler(this->contourevent);
+               wxPanel *panel = wxContourMainFrame::getInstance()->getThresholdImageViewPanel( thresholdPanel );                               
+               wxStaticText* stattext = new wxStaticText(thresholdPanel, -1, wxString(_T("   Threshold segmentation    ")), wxDefaultPosition,
+                                                                                                 wxDefaultSize, wxALIGN_CENTRE|wxBORDER_SIMPLE|wxFULL_REPAINT_ON_RESIZE, wxString(_T("")));
+               
                flexsizer->Add(stattext,wxALIGN_CENTER | wxALIGN_CENTRE);
-               flexsizer->Add(panelThreshold, wxEXPAND);
+               
+               flexsizer->Add(panel, wxEXPAND);
                thresholdPanel->Layout();
-
-       }       
+               
+       }
        showPanel(thresholdPanel);
+       wxContourMainFrame::getInstance()->changeInstant();
 }
 
+
 void interfMainPanel::ShowResultImages(int typeContourGroup, int selection, int minZ, int maxZ)
 {
        wxContourMainFrame::getInstance()->ShowResultImages(typeContourGroup, selection, minZ, maxZ);
 }
 
+
 void interfMainPanel::SetContourGroup(int contourGroup)
 {
        wxContourMainFrame::getInstance()->SetContourGroup( contourGroup);