]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
To pass into the threads pointers not references
authorapo <apo@opencascade.com>
Tue, 22 Nov 2005 11:59:59 +0000 (11:59 +0000)
committerapo <apo@opencascade.com>
Tue, 22 Nov 2005 11:59:59 +0000 (11:59 +0000)
src/VISU_I/VISU_Result_i.cc

index 415ad9dc165899f79c27798131ceb82b113659be..778dfd0851f8d8e74113e5d82933b35b067a34f3 100644 (file)
@@ -397,9 +397,9 @@ namespace
   struct TUpdateObjBrowser: public SALOME_Event
   {
     int myStudyId;
-    CORBA::Boolean& myIsDone;
+    CORBA::Boolean* myIsDone;
     TUpdateObjBrowser(const int theStudyId,
-                     CORBA::Boolean& theIsDone):
+                     CORBA::Boolean* theIsDone):
       myStudyId(theStudyId),
       myIsDone(theIsDone)
     {}
@@ -418,7 +418,7 @@ namespace
              if (myStudyId == aCStudy->StudyId()) {
                MESSAGE("Result_i::updateObjectBrowser");
                anApp->updateObjectBrowser();
-               myIsDone = true;
+               *myIsDone = true;
                break;
              }
            }
@@ -434,7 +434,7 @@ namespace
   void
   BuildGroups(VISU::Result_i* theResult,
              VISU_Convertor* theInput,
-             CORBA::Boolean& theIsDone,
+             CORBA::Boolean* theIsDone,
              SALOMEDS::Study_var theStudyDocument,
              const std::string& theRefFatherEntry)
   {
@@ -532,7 +532,7 @@ namespace
   void
   BuildFields(VISU::Result_i* theResult,
              VISU_Convertor* theInput,
-             CORBA::Boolean& theIsDone,
+             CORBA::Boolean* theIsDone,
              SALOMEDS::Study_var theStudyDocument,
              const std::string& theRefFatherEntry)
   {
@@ -637,12 +637,12 @@ namespace
   void
   BuildMinMax(VISU::Result_i* theResult,
              VISU_Convertor* theInput,
-             CORBA::Boolean& theIsDone)
+             CORBA::Boolean* theIsDone)
   {
     TMemManager aMemManager(theResult);
     
     theInput->BuildMinMax();
-    theIsDone = true;
+    *theIsDone = true;
   }
 
 
@@ -650,8 +650,8 @@ namespace
   void
   BuildMinMaxFields(VISU::Result_i* theResult,
                    VISU_Convertor* theInput,
-                   CORBA::Boolean& theFieldsIsDone,
-                   CORBA::Boolean& theMinMaxIsDone,
+                   CORBA::Boolean* theFieldsIsDone,
+                   CORBA::Boolean* theMinMaxIsDone,
                    SALOMEDS::Study_var theStudyDocument,
                    const std::string& theRefFatherEntry)
   {
@@ -690,8 +690,8 @@ VISU::Result_i
       boost::thread aThread(boost::bind(&BuildMinMaxFields,
                                        this,
                                        myInput,
-                                       myIsFieldsDone,
-                                       myIsMinMaxDone,
+                                       &myIsFieldsDone,
+                                       &myIsMinMaxDone,
                                        myStudyDocument,
                                        aRefFatherEntry));
     }
@@ -700,7 +700,7 @@ VISU::Result_i
       boost::thread aThread(boost::bind(&BuildGroups,
                                        this,
                                        myInput,
-                                       myIsGroupsDone,
+                                       &myIsGroupsDone,
                                        myStudyDocument,
                                        aRefFatherEntry));
     }
@@ -722,17 +722,17 @@ VISU::Result_i
 
     BuildFields(this,
                myInput,
-               myIsFieldsDone,
+               &myIsFieldsDone,
                myStudyDocument,
                aRefFatherEntry);
 
     BuildMinMax(this,
                myInput,
-               myIsMinMaxDone);
+               &myIsMinMaxDone);
 
     BuildGroups(this,
                myInput,
-               myIsGroupsDone,
+               &myIsGroupsDone,
                myStudyDocument,
                aRefFatherEntry);