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

index 82a494f48f9fb44b79071d934b775acd2d824e1a..78c403e93e10a6745f5b40601ee9d1db8a93aadd 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() )