SUBDIRS += src
if SALOME_MODULE
-SUBDIRS += resources bin examples test
+SUBDIRS += resources bin examples test i18n
endif
if SPHINX_IS_OK
def F_Observers(statut) : return FACT(
statut=statut,
- SELECTION = SIMP(statut="o", defaut=[], typ="TXM", min=0, max="**", validators=NoRepeat(), into=(${choices})),${decl_choices}
+ SELECTION = SIMP(statut="o", defaut=[], typ="TXM", min=0, max="**", homo="SansOrdreNiDoublon", validators=NoRepeat(), into=(${choices})),${decl_choices}
)
"""%(observers_list,observers_cont)
images/eficas_close.png \
images/eficas_open.png \
images/eficas_saveas.png \
+ images/eficas_tree.png \
images/eficas_valid.png \
images/yacs_containerlog.png
images/eficas_close.png \
images/eficas_open.png \
images/eficas_saveas.png \
+ images/eficas_tree.png \
images/eficas_valid.png \
images/yacs_containerlog.png
#
# clear ; echo ; echo -e "#\n# Debut des sources" ; echo ; \
# echo -e "TRANSLATIONS += adao_fr.ts\n\nCODECFORTR = utf-8\n" ; \
-# find .. -name '*.ui' | sed 's#^\.#FORMS += .#g' ; \
-# find ../bin -name '*.py' | sed 's#^\.#SOURCES += .#g' ; \
+# find .. -name '*.ui' | sed 's#^\.#FORMS += .#g' | sort ; \
+# find ../bin -name '*.py' | sed 's#^\.#SOURCES += .#g' | sort ; \
# find ../src -name '*.py' | grep -v tests/ | sed 's#^\.#SOURCES += .#g' ; \
# echo
#
# Create/update the .ts files with:
-# pylupdate5 i18n/adao.pro
-# geany i18n/adao_*.ts # Pour traiter si necessaire les "obsolete"
-# linguist i18n/adao_*.ts
-# lrelease i18n/adao.pro
+# pylupdate5 adao.pro
+# geany adao_*.ts # Pour traiter si necessaire les "obsolete"
+# linguist adao_*.ts
+# lrelease adao.pro
#
# Debut des sources
<context>
<name>@default</name>
<message>
- <location filename="." line="0"/>
<source>ASSIMILATION_STUDY</source>
- <translation type="obsolete">Data assimilation or optimization</translation>
+ <translation>Data assimilation or optimization</translation>
</message>
<message>
- <location filename="." line="0"/>
<source>CHECKING_STUDY</source>
- <translation type="obsolete">Verification</translation>
+ <translation>Verification</translation>
</message>
</context>
</TS>
<context>
<name>@default</name>
<message>
- <location filename="." line="0"/>
<source>ASSIMILATION_STUDY</source>
- <translation type="obsolete">Assimilation de données ou optimisation</translation>
+ <translation>Assimilation de données ou optimisation</translation>
</message>
<message>
- <location filename="." line="0"/>
<source>CHECKING_STUDY</source>
- <translation type="obsolete">Vérification</translation>
+ <translation>Vérification</translation>
</message>
</context>
</TS>
#
# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
+# Author: Jean-Philippe Argaud, jean-philippe.argaud@edf.fr, EDF R&D
import os, sys
# print "import des prefs de Adao"
-
+#
# Configuration de Eficas
+# =======================
+#
# INSTALLDIR, REPINI est obligatoire
INSTALLDIR = "@EFICAS_DIR@"
sys.path.insert(0,INSTALLDIR)
# positionnee a repin au debut mise a jour dans configuration
repIni=os.path.dirname(os.path.abspath(__file__))
-
-# initialdir sert comme directory initial des QFileDialog
+#
+# Sert comme directory initial des QFileDialog
initialdir=os.environ["PWD"]
+#
+# Traductions et codages
# Codage des strings qui accepte les accents (en remplacement de 'ascii')
encoding='iso-8859-1'
-# lang indique la langue utilisee pour les chaines d'aide : fr ou ang
-lang='fr'
+# Indique la langue du catalogue utilisee pour les chaines d'aide : fr ou ang
+# lang='fr'
+# Traduction des labels de boutons ou autres
+translatorFichier = os.environ["ADAO_ROOT_DIR"] + "/share/salome/resources/adao/adao" # Ce nom sera complete par EFICAS avec _<LANG>.qm
+#
+# Pilotage des sous-fenetres d'EFICAS
closeAutreCommande = True
closeFrameRechercheCommande = True
closeEntete = True
+closeArbre = True
taille=800
self.salome_study_item = None # Study item object
self.eficas_editor = None # Editor object from Eficas
+ self.arbreOuvert = False
def setEditor(self, editor):
if editor is not self.eficas_editor:
rtn = u"Validation report for the selected ADAO case:\n\n"
rtn += unicode( self.eficas_editor.jdc.report())
return rtn
+
+ def showTreeAdaoCase(self):
+ if self.eficas_editor:
+ if self.arbreOuvert:
+ self.eficas_editor.fermeArbre()
+ self.arbreOuvert = False
+ else:
+ self.eficas_editor.ouvreArbre()
+ self.arbreOuvert = True
+ return self.arbreOuvert
'SAVE_ADAOCASE_ID',
'SAVE_AS_ADAOCASE_ID',
'VALIDATE_ADAOCASE_ID',
+ 'SHOWTREE_ADAOCASE_ID',
'CLOSE_ADAOCASE_ID',
'YACS_EXPORT_ID',
],offset=6950)
UI_ELT_IDS.SAVE_ADAOCASE_ID:"saveAdaoCase",
UI_ELT_IDS.SAVE_AS_ADAOCASE_ID:"saveasAdaoCase",
UI_ELT_IDS.VALIDATE_ADAOCASE_ID:"validateAdaoCase",
+ UI_ELT_IDS.SHOWTREE_ADAOCASE_ID:"showTreeAdaoCase",
UI_ELT_IDS.CLOSE_ADAOCASE_ID:"closeAdaoCase",
UI_ELT_IDS.YACS_EXPORT_ID:"exportCaseToYACS",
}
adaoGuiHelper.gui_information(SalomePyQt.SalomePyQt().getDesktop(), msg)
break
+#######
+#
+# Gestion de l'affichage de l'arbre EFICAS
+# 1: la fonction showTreeAdaoCase est appelee par le GUI SALOME
+#
+#######
+
+ def showTreeAdaoCase(self):
+ adaoLogger.debug("Validation du cas par un rapport sur le JDC")
+ self.harmonizeSelectionFromEficas()
+ salomeStudyItem = adaoGuiHelper.getSelectedItem()
+ for case_name, adao_case in self.cases.iteritems():
+ if adao_case.salome_study_item.GetID() == salomeStudyItem.GetID():
+ msg = adao_case.showTreeAdaoCase()
+ break
+
#######
#
# Gestion de la connexion avec YACS
a = sgPyQt.createAction( UI_ELT_IDS.VALIDATE_ADAOCASE_ID, "Validate case", "Validate case", "Validate an ADAO case", "eficas_valid.png" )
sgPyQt.createMenu(a, mid)
sgPyQt.createTool(a, tid)
+ a = sgPyQt.createAction( UI_ELT_IDS.SHOWTREE_ADAOCASE_ID, "Show tree", "Show tree", "Show the commands tree", "eficas_tree.png" )
+ sgPyQt.createMenu(a, mid)
+ sgPyQt.createTool(a, tid)
a = sgPyQt.createAction( UI_ELT_IDS.CLOSE_ADAOCASE_ID, "Close case", "Close case", "Close an ADAO case", "eficas_close.png" )
sgPyQt.createMenu(a, mid)
sgPyQt.createTool(a, tid)