]> SALOME platform Git repositories - tools/install.git/commitdiff
Salome HOME
PAL12079
authorvsr <vsr@opencascade.com>
Fri, 21 Apr 2006 10:48:44 +0000 (10:48 +0000)
committervsr <vsr@opencascade.com>
Fri, 21 Apr 2006 10:48:44 +0000 (10:48 +0000)
bin/SALOME_InstallWizard
src/SALOME_InstallWizard.cxx

index b11011676bbde12f94264969ae8d1fa35bc2fb2a..cecf285d07bc29e609ab10c4f76b4509e3ec5115 100755 (executable)
Binary files a/bin/SALOME_InstallWizard and b/bin/SALOME_InstallWizard differ
index 36737b440493ebbe8847e78848bf61a1a4dcc872..657acd66f952bc8d8849b9735533930bc1ae4c5b 100644 (file)
@@ -1364,17 +1364,15 @@ void SALOME_InstallWizard::checkProductPage()
   for ( itProd = productsMap.begin(); itProd != productsMap.end(); ++itProd ) {
     bool srcctx = itProd.data().hasContext( "salome sources" );
     bool binctx = itProd.data().hasContext( "salome binaries" );
-    if ( srcctx ) totSrc++;
-    if ( binctx ) totBin++;
-    if ( srcctx && !binctx && productsView->isSources( itProd.key() ) )
-      selSrc++;
-    if ( !srcctx && binctx && productsView->isBinaries( itProd.key() ) )
-      selBin++;
-    if ( srcctx && binctx && 
-        ( productsView->isSources( itProd.key() ) || 
-          productsView->isBinaries( itProd.key() ) ) ) {
-      selSrc++;
-      selBin++;
+    if ( srcctx && !binctx ) {
+      totSrc++;
+      if ( productsView->isSources( itProd.key() ) )
+       selSrc++;
+    }
+    if ( binctx && !srcctx ) {
+      totBin++;
+      if ( productsView->isBinaries( itProd.key() ) )
+       selBin++;
     }
   }
   selectSrcBtn->blockSignals( true );
@@ -2111,8 +2109,18 @@ void SALOME_InstallWizard::onProdBtn()
     MapProducts::Iterator itProd;
     for ( itProd = productsMap.begin(); itProd != productsMap.end(); ++itProd ) {
       if ( itProd.data().hasContext( "salome sources" ) ) {
-       if ( checkBox->state() == QButton::Off )
-         productsView->setNone( itProd.key() );
+       if ( checkBox->state() == QButton::Off ) {
+         int selBin = 0;
+         MapProducts::Iterator itProd1;
+         for ( itProd1 = productsMap.begin(); itProd1 != productsMap.end(); ++itProd1 ) {
+           if (  itProd1.data().hasContext( "salome binaries" ) && 
+                !itProd1.data().hasContext( "salome sources" ) &&
+                 productsView->isBinaries( itProd1.key() ) )
+             selBin++;
+         }
+         if ( !itProd.data().hasContext( "salome binaries" ) || !selBin )
+           productsView->setNone( itProd.key() );
+       }
        else {
          productsView->setSources( itProd.key() );
          if ( prerequisites->isChecked() )
@@ -2128,8 +2136,18 @@ void SALOME_InstallWizard::onProdBtn()
     MapProducts::Iterator itProd;
     for ( itProd = productsMap.begin(); itProd != productsMap.end(); ++itProd ) {
       if ( itProd.data().hasContext( "salome binaries" ) ) {
-       if ( checkBox->state() == QButton::Off )
-         productsView->setNone( itProd.key() );
+       if ( checkBox->state() == QButton::Off ) {
+         int selSrc = 0;
+         MapProducts::Iterator itProd1;
+         for ( itProd1 = productsMap.begin(); itProd1 != productsMap.end(); ++itProd1 ) {
+           if (  itProd1.data().hasContext( "salome sources" ) && 
+                !itProd1.data().hasContext( "salome binaries" ) &&
+                 productsView->isSources( itProd1.key() ) )
+             selSrc++;
+         }
+         if ( !itProd.data().hasContext( "salome sources" ) || !selSrc )
+           productsView->setNone( itProd.key() );
+       }
        else {
          productsView->setBinaries( itProd.key() );
          if ( prerequisites->isChecked() )