]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
0021935: [CEA 696] Possibility to delete an object even if it was used before to...
authorvsr <vsr@opencascade.com>
Mon, 27 May 2013 15:19:08 +0000 (15:19 +0000)
committervsr <vsr@opencascade.com>
Mon, 27 May 2013 15:19:08 +0000 (15:19 +0000)
src/GEOMGUI/GEOM_msg_en.ts
src/GEOMGUI/GEOM_msg_fr.ts
src/GEOMToolsGUI/GEOMToolsGUI.cxx

index 62a43007afd343b5e121809b81c9784d7a6529a6..14a91c3205487c5abd258976fc4e6c492956fee7 100644 (file)
     </message>
     <message>
         <source>DEP_OBJECT</source>
-        <translation>Selected object has been used to create another one.
-It can&apos;t be deleted </translation>
+        <translation>One or more selected objects are used to create another ones or referenced from other modules.
+Removal of these objects can result in valid Python dump.
+
+Do you still want to delete these objects?</translation>
     </message>
     <message>
         <source>DEVIDE_EDGE_NEW_OBJECT_NAME</source>
index 15354dfd5dbe3163fcd33dbd86a8dc8351a676c6..ca76c8bcabf20424f053c03d0f76129896ddf4cd 100644 (file)
@@ -29,7 +29,7 @@
     </message>
     <message>
         <source>DEP_OBJECT</source>
-        <translation>L&apos;objet choisi a été utilisé pour créer un autre objet.
+        <translation type="unfinished">L&apos;objet choisi a été utilisé pour créer un autre objet.
 Il n&apos;est pas possible de le supprimer </translation>
     </message>
     <message>
index 9d6c00c1a3e993ea52c5f7d81736c9cc43e38c43..2b8a4abcb354a31550b0729b62402d9c3486a607 100644 (file)
@@ -543,10 +543,12 @@ void GEOMToolsGUI::OnEditDelete()
   }
   else {
     // GEOM component is not selected: check if selected objects are in use
-    if ( inUse( aStudy, geomComp, allDeleted ) ) {
-      SUIT_MessageBox::warning( app->desktop(),
-                                QObject::tr("WRN_WARNING"),
-                                QObject::tr("DEP_OBJECT") );
+    if ( inUse( aStudy, geomComp, allDeleted ) && 
+        SUIT_MessageBox::question( app->desktop(),
+                                   QObject::tr("WRN_WARNING"),
+                                   QObject::tr("DEP_OBJECT"),
+                                   SUIT_MessageBox::Yes | SUIT_MessageBox::No,
+                                   SUIT_MessageBox::No ) != SUIT_MessageBox::Yes ) {
       return; // object(s) in use
     }
     // ... and then delete all objects