Salome HOME
PAL10853 V_3_1_0b1
authorvsr <vsr@opencascade.com>
Tue, 13 Dec 2005 14:46:55 +0000 (14:46 +0000)
committervsr <vsr@opencascade.com>
Tue, 13 Dec 2005 14:46:55 +0000 (14:46 +0000)
bin/SALOME_InstallWizard
config.xml
config_Mandrake_10.1.xml
config_RedHat_8.0.xml
config_RedHat_9.xml
config_Scientific_3.0.5.xml
doc/readme.html
src/SALOME_InstallWizard.cxx
src/SALOME_InstallWizard.hxx

index 389af2e2b7d3c0bbc5f5927383d15f10cc588be3..08dae42cbd455057a4fba23fafebe666bd4e7a42 100755 (executable)
Binary files a/bin/SALOME_InstallWizard and b/bin/SALOME_InstallWizard differ
index c79773726d2eaff496de338a7669a1ae17ca7409..2b7f353ee890c3cfbc7946dbfc5254664935e365 100644 (file)
           script="LIGHT_BIN.sh"/>
   <product name="SAMPLES"
            version="3.1.0b1" 
+           context="salome sources,salome binaries" 
            description="SALOME samples files"
            install="install sources"
           supported="install sources"
index f705c4517dd77d0ebe0352fcd24d8b48d4f4287f..3b583fe0522cc4773a6cbf706a82bda24e8dba14 100755 (executable)
           script="LIGHT_BIN.sh"/>
   <product name="SAMPLES"
            version="3.1.0b1" 
+           context="salome sources,salome binaries" 
            description="SALOME samples files"
            install="install sources"
           supported="install sources"
index 468d20b11a1e6644d78b9405460941caee5e520f..f70cb8aac172b995b835bd676f6a02e8308cb69d 100755 (executable)
           script="LIGHT_BIN.sh"/>
   <product name="SAMPLES"
            version="3.1.0b1" 
+           context="salome sources,salome binaries" 
            description="SALOME samples files"
            install="install sources"
           supported="install sources"
index 12bd3f911bbab5104bc4f7ab4796c0f381074b46..9d8575144b00fac0e359558983353cfc8ff78ddc 100755 (executable)
           script="LIGHT_BIN.sh"/>
   <product name="SAMPLES"
            version="3.1.0b1" 
+           context="salome sources,salome binaries" 
            description="SALOME samples files"
            install="install sources"
           supported="install sources"
index ac36e868e8360f1fd2f3abe5e3c658b7dba7e780..76706382cafbfb73298935cb8c73851033c682b9 100755 (executable)
           script="LIGHT_BIN.sh"/>
   <product name="SAMPLES"
            version="3.1.0b1" 
+           context="salome sources,salome binaries" 
            description="SALOME samples files"
            install="install sources"
           supported="install sources"
index c21dd8e6397db0619cc8f45846e8c2ddbd97114e..ec9f11ece70abe20127c0dea0153593cccc32014 100755 (executable)
@@ -163,10 +163,13 @@ have
 installed.
 Therefore all these products will be marked when you check on <b><i>PyQt</i></b>.
 This feature can be switched off by clicking <i>"Auto set
-prerequisites products"</i> checkbox. <br>
+prerequisites products"</i> checkbox. Turn on this checkbox if you
+want all pre-requisite products to be automatically checked when you
+select some product to be installed. Turn off this checkbox if you
+want to disable this feature.<br><br>
 Special button in the right part of the page - <i>"Unselect All" </i>-
 allows to reset quickly all products to the <i>"not install"</i>
-state. <br>
+state. <br><br>
 If you want to use native products (like <span
  style="font-weight: bold;">gcc</span>, <span
  style="font-weight: bold;">tcl</span>, etc.), select <i>"use native" </i>option.
index a51e1ea6c9d69e87e23f31f5d74ce6fddea8df17..f85b34b686e5cc486b17e59db88a0ee1d47ce441 100644 (file)
@@ -1182,15 +1182,19 @@ void SALOME_InstallWizard::checkProductPage()
   int totBin = 0, selBin = 0;
   MapProducts::Iterator itProd;
   for ( itProd = productsMap.begin(); itProd != productsMap.end(); ++itProd ) {
-    if ( itProd.data().getContext() == "salome sources" ) {
-      totSrc++;
-      if ( productsView->isSources( itProd.key() ) )
-       selSrc++;
-    }
-    if ( itProd.data().getContext() == "salome binaries" ) {
-      totBin++;
-      if ( productsView->isBinaries( itProd.key() ) )
-       selBin++;
+    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++;
     }
   }
   selectSrcBtn->blockSignals( true );
@@ -1889,11 +1893,14 @@ void SALOME_InstallWizard::onProdBtn()
       checkBox->setState( QButton::On );
     MapProducts::Iterator itProd;
     for ( itProd = productsMap.begin(); itProd != productsMap.end(); ++itProd ) {
-      if ( itProd.data().getContext() == "salome sources" ) {
+      if ( itProd.data().hasContext( "salome sources" ) ) {
        if ( checkBox->state() == QButton::Off )
          productsView->setNone( itProd.key() );
-       else
+       else {
          productsView->setSources( itProd.key() );
+         if ( prerequisites->isChecked() )
+           setPrerequisites( itProd.key() );
+       }
       }
     }
   }
@@ -1903,11 +1910,14 @@ void SALOME_InstallWizard::onProdBtn()
       checkBox->setState( QButton::On );
     MapProducts::Iterator itProd;
     for ( itProd = productsMap.begin(); itProd != productsMap.end(); ++itProd ) {
-      if ( itProd.data().getContext() == "salome binaries" ) {
+      if ( itProd.data().hasContext( "salome binaries" ) ) {
        if ( checkBox->state() == QButton::Off )
          productsView->setNone( itProd.key() );
-       else
+       else {
          productsView->setBinaries( itProd.key() );
+         if ( prerequisites->isChecked() )
+           setPrerequisites( itProd.key() );
+       }
       }
     }
   }
index 551e43c20fb513246462b9a7483854f758b5796b..dd9e4d76a706851baef3ea376d44ddf771ee95ca 100644 (file)
@@ -53,13 +53,22 @@ class Dependancies
   // gets dependancies
   QStringList getDependancies() const { return dependsOn; }
   // gets disk space required
-  long        getSize(bool sources = false) const { return ( sources ? sizeSourcesTotal : sizeBinaryTotal ); }
+  long        getSize(bool sources = false) const 
+  { 
+    return ( sources ? sizeSourcesTotal : sizeBinaryTotal ); 
+  }
   // gets temporary disk space required
   long        getTempSize() const     { return sizeTemp;   }
   // gets product's description
   QString     getDescription() const  { return description; }
   // gets product's context
   QString     getContext() const      { return context; }
+  // returns true if product supports given context
+  bool        hasContext( const QString& ctx ) const
+  {
+    QStringList cl = QStringList::split(",",context);
+    return cl.find( ctx ) != cl.end();
+  }
   // gets default mode
   QString     getDefault() const      { return defaultMode; }
   // returns true if this product needs to pick-up environment