]> Creatis software - creaMaracasVisu.git/commitdiff
no message EED.02Oct2009
authorEduardo Davila <Eduardo.Davila@creatis.insa-lyon.fr>
Fri, 25 Sep 2009 10:58:19 +0000 (10:58 +0000)
committerEduardo Davila <Eduardo.Davila@creatis.insa-lyon.fr>
Fri, 25 Sep 2009 10:58:19 +0000 (10:58 +0000)
lib/maracasVisuLib/src/CutModule/kernel/CutModelException.cxx
lib/maracasVisuLib/src/CutModule/kernel/CutModelException.h
lib/maracasVisuLib/src/interface/wxWindows/widgets/manualContour/manualViewBaseContour.cpp
lib/maracasVisuLib/src/interface/wxWindows/widgets/manualContour/manualViewContour.cpp

index c20984f8fa5a53f88ba784915dfb8a7c524a8c86..de2574676b1d1c3cf09d5cf448ac541fb5a2811d 100644 (file)
@@ -3,8 +3,8 @@
   Program:   wxMaracas
   Module:    $RCSfile: CutModelException.cxx,v $
   Language:  C++
-  Date:      $Date: 2009/08/31 08:46:11 $
-  Version:   $Revision: 1.1 $
+  Date:      $Date: 2009/09/25 10:58:19 $
+  Version:   $Revision: 1.2 $
 
   Copyright: (c) 2002, 2003
   License:
@@ -23,7 +23,7 @@ CutModelException::CutModelException(std::string cause)
 :std::exception(){
     _cause = cause;    
 }
-CutModelException::~CutModelException(){
+CutModelException::~CutModelException()throw(){
 }
 
 
index d4461a65db6992caddcb1949ca44d539947d416f..1c258713826185dce5e5e34f74d5d4e794e64a45 100644 (file)
@@ -3,8 +3,8 @@
   Program:   wxMaracas
   Module:    $RCSfile: CutModelException.h,v $
   Language:  C++
-  Date:      $Date: 2009/08/31 08:46:11 $
-  Version:   $Revision: 1.1 $
+  Date:      $Date: 2009/09/25 10:58:19 $
+  Version:   $Revision: 1.2 $
 
   Copyright: (c) 2002, 2003
   License:
@@ -29,7 +29,7 @@ class CutModelException  : public std::exception{
 
 public:
        CutModelException(std::string cause);
-       ~CutModelException();
+       ~CutModelException() throw();
 
        std::string getCause(){
                return _cause;
index 4ab822f8630bbde4369abdf19d404dc2f207b542..e7e0bea99c93935d46a54d0ed684d997f52a815d 100644 (file)
@@ -495,6 +495,7 @@ bool manualViewBaseContour::SelectPosibleContour(int x, int y, int z)
        bool result=false;
        SetPosibleSelected(result);
     int id = GetIdPoint(x,y,z);
+               
        if( !GetEditable() && !_selected && id!= -1)
        {
                result=true;
index f35e2311f4a218b7d2c202f34e357b2f8a3d051a..4fcd7228798e90ea5acf0a56a9ba7205e52fb63f 100644 (file)
@@ -161,6 +161,7 @@ void manualViewContour::RefreshText()  // virtual
 
 // ----------------------------------------------------------------------------
 bool manualViewContour::ifTouchContour(int x,int y,int z){
+       
        bool result=false;
        double xx=x;
        double yy=y;
@@ -194,12 +195,19 @@ bool manualViewContour::ifTouchContour(int x,int y,int z){
                d2= sqrt( (ppB[0]-xx)*(ppB[0]-xx) + (ppB[1]-yy)*(ppB[1]-yy) + (ppB[2]-zz)*(ppB[2]-zz));
                d3= sqrt( (ppB[0]-ppA[0])*(ppB[0]-ppA[0]) + (ppB[1]-ppA[1])*(ppB[1]-ppA[1]) + (ppB[2]-ppA[2])*(ppB[2]-ppA[2]));
 
-
                if (  ((d1+d2)>=d3) &&  ((d1+d2)<=d3*1.3) ) 
+               {
+                       result=true;
+                       i=nps;
+               } 
+               
+               //EED 25 Sep 2009
+               if ((d1<=1) || (d2<=1))
                {
                        result=true;
                        i=nps;
                }
+               
        }
        
        return result;