From 1dbd886d7b34b0eceb1137d1c3d89cd5342b29f7 Mon Sep 17 00:00:00 2001 From: Pascale Noyret Date: Fri, 19 Oct 2007 13:44:12 +0000 Subject: [PATCH] *** empty log message *** --- InterfaceQT/monFonctionPanel.py | 19 ++++- InterfaceQT/monParamPanel.py | 12 ++- InterfaceQT/monPlusieursBasePanel.py | 14 +++- InterfaceQT/monSelectVal.py | 84 ++++++++++++++++++++ InterfaceQT/monUniqueASSDPanel.py | 2 +- InterfaceQT/monUniqueBasePanel.py | 6 ++ InterfaceQT/monUniqueSDCOIntoPanel.py | 107 ++++++++++++++++++++++++++ InterfaceQT/monUniqueSDCOPanel.py | 64 +++++++++++++++ InterfaceQT/politiquesValidation.py | 2 + InterfaceQT/qtCommun.py | 5 ++ InterfaceQT/qtEficas.py | 2 - InterfaceQT/qtSaisie.py | 44 +++++++++-- InterfaceQT/viewManager.py | 16 ---- Ui/desListeParam.py | 42 ++++++++++ Ui/desListeParam.ui | 44 +++++++++++ 15 files changed, 431 insertions(+), 32 deletions(-) create mode 100644 InterfaceQT/monSelectVal.py create mode 100644 InterfaceQT/monUniqueSDCOIntoPanel.py create mode 100644 InterfaceQT/monUniqueSDCOPanel.py create mode 100644 Ui/desListeParam.py create mode 100644 Ui/desListeParam.ui diff --git a/InterfaceQT/monFonctionPanel.py b/InterfaceQT/monFonctionPanel.py index 272c89af..9bde8dc0 100644 --- a/InterfaceQT/monFonctionPanel.py +++ b/InterfaceQT/monFonctionPanel.py @@ -67,8 +67,12 @@ class MonFonctionPanel(MonPlusieursBasePanel): for valeur in self.DecoupeListeValeurs(listeValeurs): self.LBValeurs.insertItem(str(valeur)) - def Ajout1Valeur(self): - liste,validite=self.TraiteLEValeur() + def Ajout1Valeur(self,liste=[]): + # Pour être appele a partir du Panel Importer (donc plusieurs fois par AjouterNValeur) + if liste == [] : + liste,validite=SaisieValeur.TraiteLEValeur(self) + else : + validite=1 if validite == 0 : return if liste ==[] : return @@ -102,6 +106,16 @@ class MonFonctionPanel(MonPlusieursBasePanel): self.listeValeursCourantes=l1+listeRetour+l3 + def AjoutNValeur(self,liste) : + if len(liste)%self.nbValeurs != 0 : + texte="Nombre de valeur incorrecte" + self.Commentaire.setText(texte) + return + listeDecoupee=self.DecoupeListeValeurs(liste) + for vals in listeDecoupee : + self.Ajout1Valeur(vals) + + def Sup1Valeur(self): index=self.LBValeurs.currentItem() self.LBValeurs.removeItem(self.LBValeurs.currentItem()) @@ -115,7 +129,6 @@ class MonFonctionPanel(MonPlusieursBasePanel): else : print "aiiiiiiiiiiiiiiiiiieeee" i = i+1 - print listeVal self.listeValeursCourantes=listeVal listeValeurs=self.listeValeursCourantes self.LBValeurs.clear() diff --git a/InterfaceQT/monParamPanel.py b/InterfaceQT/monParamPanel.py index 2abe2745..33145e9e 100644 --- a/InterfaceQT/monParamPanel.py +++ b/InterfaceQT/monParamPanel.py @@ -78,14 +78,22 @@ class MonParamPanel(DParam,QTPanelTBW2,QTPanel): self.Commentaire.setText(QString("")) commentaire="Valeur incorrecte" qtVal=self.lineEditVal.text() + boul=2 try : - val,boul=QString.toFloat(qtVal) + val,boul=QString.toInt(qtVal) except : + pass + if boul == 0 : try : - val,boul=QString.toInt(qtVal) + val,boul=QString.toFloat(qtVal) except : + pass + if boul == 0 : + try : val=str(qtVal) boul=1 + except : + pass if boul: commentaire="Valeur correcte" self.Commentaire.setText(QString(commentaire)) return val diff --git a/InterfaceQT/monPlusieursBasePanel.py b/InterfaceQT/monPlusieursBasePanel.py index f53f67f6..c6e59a8d 100644 --- a/InterfaceQT/monPlusieursBasePanel.py +++ b/InterfaceQT/monPlusieursBasePanel.py @@ -57,6 +57,9 @@ class MonPlusieursBasePanel(DPlusBase,QTPanel,SaisieValeur): def BSupPressed(self): QTPanel.BSupPressed(self) + def BParametresPressed(self): + QTPanel.BParametresPressed(self) + def LEValeurPressed(self): self.Ajout1Valeur() @@ -72,8 +75,8 @@ class MonPlusieursBasePanel(DPlusBase,QTPanel,SaisieValeur): self.listeValeursCourantes=listeVal - def Ajout1Valeur(self): - liste,validite=SaisieValeur.TraiteLEValeur(self) + def Ajout1Valeur(self,valeur=None): + liste,validite=SaisieValeur.TraiteLEValeur(self,valeur) if validite == 0 : return if liste ==[] : return @@ -94,3 +97,10 @@ class MonPlusieursBasePanel(DPlusBase,QTPanel,SaisieValeur): index=index+1 self.listeValeursCourantes=l1+listeRetour+l3 + def BImportPressed(self): + init=QString( self.editor.CONFIGURATION.rep_user) + fn = QFileDialog.getOpenFileName(init, self.trUtf8('All Files (*)',)) + if fn == None : return + if fn == "" : return + from monSelectVal import MonSelectVal + MonSelectVal(file=fn,parent=self).show() diff --git a/InterfaceQT/monSelectVal.py b/InterfaceQT/monSelectVal.py new file mode 100644 index 00000000..c3c64148 --- /dev/null +++ b/InterfaceQT/monSelectVal.py @@ -0,0 +1,84 @@ +# -*- coding: utf-8 -*- +# CONFIGURATION MANAGEMENT OF EDF VERSION +# ====================================================================== +# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG +# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY +# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY +# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR +# (AT YOUR OPTION) ANY LATER VERSION. +# +# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT +# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF +# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU +# GENERAL PUBLIC LICENSE FOR MORE DETAILS. +# +# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE +# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER, +# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE. +# +# +# ====================================================================== +# Modules Python +# Modules Eficas + +from desSelectVal import DSelVal +from qt import * + +# Import des panels + +class MonSelectVal(DSelVal): + """ + Classe définissant le panel associé aux mots-clés qui demandent + à l'utilisateur de choisir une seule valeur parmi une liste de valeurs + discrètes + """ + def __init__(self,file,parent,name = None,fl = 0): + self.FonctPanel=parent + DSelVal.__init__(self,parent,name,Qt.WType_Dialog) + self.dictSepar={} + self.separateur=" " + self.texte=" " + self.textTraite="" + self.file=str(file) + self.readVal() + self.initVal() + + def readVal(self): + f = open(self.file, "rb") + self.texte = f.read() + f.close() + + def initVal(self): + self.TBtext.clear() + self.TBtext.setText(self.texte) + self.dictSepar["virgule"]="," + self.dictSepar["point-virgule"]=";" + self.dictSepar["espace"]=" " + + def SeparateurSelect(self,numero): + monBouton=self.BGSeparateur.find(numero) + self.separateur=self.dictSepar[str(monBouton.text())] + + def BImportSelPressed(self): + text=str(self.TBtext.selectedText()) + self.textTraite=text + self.Traitement() + + def BImportToutPressed(self): + self.textTraite=self.texte + self.Traitement() + + def Traitement(self): + import string + if self.textTraite[-1]=="\n" : self.textTraite=self.textTraite[0:-1] + self.textTraite=string.replace(self.textTraite,"\n",self.separateur) + liste1=self.textTraite.split(self.separateur) + liste=[] + for val in liste1 : + val=str(val) + try : + val=eval(val,{}) + except : + pass + liste.append(val) + self.FonctPanel.AjoutNValeur(liste) diff --git a/InterfaceQT/monUniqueASSDPanel.py b/InterfaceQT/monUniqueASSDPanel.py index 7bc1cdfb..d41c7082 100644 --- a/InterfaceQT/monUniqueASSDPanel.py +++ b/InterfaceQT/monUniqueASSDPanel.py @@ -46,7 +46,7 @@ class MonUniqueASSDPanel(DUnASSD,QTPanel,SaisieValeur): self.InitListBoxASSD() def BOkPressed(self): - self.clicASSD() + self.ClicASSD() def BSupPressed(self): QTPanel.BSupPressed(self) diff --git a/InterfaceQT/monUniqueBasePanel.py b/InterfaceQT/monUniqueBasePanel.py index 8e83ec86..bbac7773 100644 --- a/InterfaceQT/monUniqueBasePanel.py +++ b/InterfaceQT/monUniqueBasePanel.py @@ -63,3 +63,9 @@ class MonUniqueBasePanel(DUnBase,QTPanel,SaisieValeur): def LEValeurPressed(self): SaisieValeur.LEValeurPressed(self) + + def BParametresPressed(self): + QTPanel.BParametresPressed(self) + + def Ajout1Valeur(self,valeur): + SaisieValeur.LEValeurPressed(self,valeur) diff --git a/InterfaceQT/monUniqueSDCOIntoPanel.py b/InterfaceQT/monUniqueSDCOIntoPanel.py new file mode 100644 index 00000000..7890d151 --- /dev/null +++ b/InterfaceQT/monUniqueSDCOIntoPanel.py @@ -0,0 +1,107 @@ +# -*- coding: utf-8 -*- +# CONFIGURATION MANAGEMENT OF EDF VERSION +# ====================================================================== +# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG +# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY +# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY +# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR +# (AT YOUR OPTION) ANY LATER VERSION. +# +# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT +# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF +# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU +# GENERAL PUBLIC LICENSE FOR MORE DETAILS. +# +# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE +# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER, +# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE. +# +# +# ====================================================================== +# Modules Python +import string,types,os + +# Modules Eficas +from Aster import prefs + +from qt import * + +from desUniqueSDCOInto import DUnSDCOInto +from qtCommun import QTPanel +from qtSaisie import SaisieSDCO +from politiquesValidation import PolitiqueUnique + +# Import des panels + +class MonUniqueSDCOIntoPanel(DUnSDCOInto,QTPanel,SaisieSDCO): + """ + Classe définissant le panel associé aux mots-clés qui demandent + à l'utilisateur de choisir une seule valeur parmi une liste de valeurs + discrètes + """ + def __init__(self,node, parent = None,name = None,fl = 0): + QTPanel.__init__(self,node,parent) + DUnSDCOInto.__init__(self,parent,name,fl) + self.initLBSDCO() + + def initLBSDCO(self): + listeNomsSDCO = self.node.item.get_sd_avant_du_bon_type() + for aSDCO in listeNomsSDCO: + self.LBSDCO.insertItem( aSDCO) + valeur = self.node.item.get_valeur() + if valeur != "" and valeur != None : + self.LESDCO.setText(QString(valeur.nom)) + + def BOuiPressed(self): + self.rbOui.setChecked(1) + self.rbNon.setChecked(0) + self.LESDCO.setEnabled(1) + self.disconnect(self.LBSDCO,SIGNAL("clicked(QListBoxItem*)"),self.LBSDCOReturnPressed) + self.LBSDCO.clear() + + def BNonPressed(self): + self.rbOui.setChecked(0) + self.rbNon.setChecked(1) + self.LESDCO.setEnabled(0) + self.initLBSDCO() + self.connect(self.LBSDCO,SIGNAL("clicked(QListBoxItem*)"),self.LBSDCOReturnPressed) + + def LBSDCOReturnPressed(self): + """ + Teste si la valeur fournie par l'utilisateur est une valeur permise : + - si oui, l'enregistre + - si non, restaure l'ancienne valeur + """ + nomConcept=str(self.LBSDCO.currentText()) + self.editor.init_modif() + anc_val = self.node.item.get_valeur() + test_CO=self.node.item.is_CO(anc_val) + + valeur,validite=self.node.item.eval_valeur(nomConcept) + test = self.node.item.set_valeur(valeur) + if not test : + commentaire = "impossible d'évaluer : %s " %`valeur` + elif validite: + commentaire = "Valeur du mot-clé enregistrée" + if test_CO: + # il faut egalement propager la destruction de l'ancien concept + self.node.item.delete_valeur_co(valeur=anc_val) + self.node.item.object.etape.get_type_produit(force=1) + self.node.item.object.etape.parent.reset_context() + else : + commentaire = self.node.item.get_cr() + self.reset_old_valeur(anc_val,mess=mess) + self.Commentaire.setText(commentaire) + + def LESDCOReturnPressed(self) : + SaisieSDCO.LESDCOReturnPressed(self) + + def BOkPressed(self): + if self.rbOui.isChecked(): + self.LESDCOReturnPressed() + else: + self.LBSDCOReturnPressed() + + def BSupPressed(self): + QTPanel.BSupPressed(self) + diff --git a/InterfaceQT/monUniqueSDCOPanel.py b/InterfaceQT/monUniqueSDCOPanel.py new file mode 100644 index 00000000..dd23f829 --- /dev/null +++ b/InterfaceQT/monUniqueSDCOPanel.py @@ -0,0 +1,64 @@ +# -*- coding: utf-8 -*- +# CONFIGURATION MANAGEMENT OF EDF VERSION +# ====================================================================== +# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG +# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY +# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY +# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR +# (AT YOUR OPTION) ANY LATER VERSION. +# +# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT +# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF +# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU +# GENERAL PUBLIC LICENSE FOR MORE DETAILS. +# +# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE +# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER, +# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE. +# +# +# ====================================================================== +# Modules Python +import string,types,os + +# Modules Eficas +from Aster import prefs + +from qt import * + +from desUniqueSDCO import DUnSDCO +from qtCommun import QTPanel +from qtSaisie import SaisieSDCO + +# Import des panels + +class MonUniqueSDCOPanel(DUnSDCO,QTPanel,SaisieSDCO): + """ + Classe définissant le panel associé aux mots-clés qui demandent + à l'utilisateur de choisir une seule valeur parmi une liste de valeurs + discrètes + """ + def __init__(self,node, parent = None,name = None,fl = 0): + QTPanel.__init__(self,node,parent) + DUnSDCO.__init__(self,parent,name,fl) + valeur = self.node.item.get_valeur() + if valeur != "" and valeur != None : + self.LESDCO.setText(QString(valeur.nom)) + + def BOkPressed(self): + SaisieSDCO.LESDCOReturnPressed(self) + + def BSupPressed(self): + QTPanel.BSupPressed(self) + + def BOuiPressed(self): + self.Commentaire.setText("Aucun Objet de ce type n'est defini") + self.rbOui.setChecked(1) + + def LESDCOReturnPressed(self): + """ + Lit le nom donné par l'utilisateur au concept de type CO qui doit être + la valeur du MCS courant et stocke cette valeur + """ + SaisieSDCO.LESDCOReturnPressed(self) + diff --git a/InterfaceQT/politiquesValidation.py b/InterfaceQT/politiquesValidation.py index dd04a650..7509da01 100644 --- a/InterfaceQT/politiquesValidation.py +++ b/InterfaceQT/politiquesValidation.py @@ -21,6 +21,8 @@ # Modules Python import types +from qt import * + #------------------ class Validation : diff --git a/InterfaceQT/qtCommun.py b/InterfaceQT/qtCommun.py index 7a376c8f..def3ca0f 100644 --- a/InterfaceQT/qtCommun.py +++ b/InterfaceQT/qtCommun.py @@ -62,6 +62,11 @@ class QTPanel: if label==QString("Fichier Include"): self.BOkIncPressed() + def BParametresPressed(self): + liste=self.node.item.get_liste_param_possible() + from monListeParamPanel import MonListeParamPanel + MonListeParamPanel(liste=liste,parent=self).show() + def AppelleBuildLBRegles(self): listeRegles = self.node.item.get_regles() listeNomsEtapes = self.node.item.get_mc_presents() diff --git a/InterfaceQT/qtEficas.py b/InterfaceQT/qtEficas.py index 199e82b4..5cb6ee38 100644 --- a/InterfaceQT/qtEficas.py +++ b/InterfaceQT/qtEficas.py @@ -126,7 +126,6 @@ class Appli(Eficas): """ Public slot to handle the lastEditorClosed signal. """ - print 10*"handleLastEditorClosed: CS_pbruno todo griser les parties k'il faut " pass # CS_pbruno todo griser les parties k'il faut def handleEditorOpened(self, fn): @@ -135,7 +134,6 @@ class Appli(Eficas): @param fn filename of the opened editor (string) """ - print 10*"handleEditorOpened: CS_pbruno todo griser les parties k'il faut " pass # CS_pbruno todo degriser les parties k'il faut diff --git a/InterfaceQT/qtSaisie.py b/InterfaceQT/qtSaisie.py index d8ddcecd..aa112a45 100644 --- a/InterfaceQT/qtSaisie.py +++ b/InterfaceQT/qtSaisie.py @@ -87,15 +87,16 @@ class SaisieValeur: else : self.LEValeurPressed() - def LEValeurPressed(self): - nouvelleValeur=str(self.lineEditVal.text()) + def LEValeurPressed(self,valeur=None): + if valeur == None : + nouvelleValeur=str(self.lineEditVal.text()) + else : + self.lineEditVal.setText(QString(valeur.nom)) + nouvelleValeur=valeur validite,commentaire=self.politique.RecordValeur(nouvelleValeur) if commentaire != "" : self.Commentaire.setText(QString(commentaire)) - def BParametresPressed(self): - print "a faire" - def TraiteLEValeur(self,valeurTraitee=None) : # lit la chaine entree dans le line edit @@ -106,7 +107,6 @@ class SaisieValeur: valeurBrute=str(self.LEValeur.text()) else : valeurBrute=valeurTraitee - print type(valeurBrute) if valeurBrute == str("") : return 1, listeValeurs try : valeur=eval(valeurBrute,{}) @@ -142,3 +142,35 @@ class SaisieValeur: listeValeurs.append(valeur) return listeValeurs,1 + + +class SaisieSDCO : + def __init__(self): + pass + + def LESDCOReturnPressed(self): + """ + Lit le nom donné par l'utilisateur au concept de type CO qui doit être + la valeur du MCS courant et stocke cette valeur + """ + self.editor.init_modif() + anc_val = self.node.item.get_valeur() + if anc_val != None: + # il faut egalement propager la destruction de l'ancien concept + self.node.item.delete_valeur_co(valeur=anc_val) + # et on force le recalcul des concepts de sortie de l'etape + self.node.item.object.etape.get_type_produit(force=1) + # et le recalcul du contexte + self.node.item.object.etape.parent.reset_context() + nomConcept = str(self.LESDCO.text()) + if nomConcept == "" : return + + test,commentaire=self.node.item.set_valeur_co(nomConcept) + if test: + commentaire="Valeur du mot-clé enregistree" + self.node.update_node_valid() + else : + cr = self.node.item.get_cr() + commentaire = "Valeur du mot-clé non autorisée :"+cr.get_mess_fatal() + self.node.item.set_valeur_co(anc_val) + self.Commentaire.setText(QString(commentaire)) diff --git a/InterfaceQT/viewManager.py b/InterfaceQT/viewManager.py index c06e9c2b..afa9cc82 100644 --- a/InterfaceQT/viewManager.py +++ b/InterfaceQT/viewManager.py @@ -630,7 +630,6 @@ class ViewManager: @return flag indicating successful reset of the dirty flag (boolean) """ if editor.modified: - print 'CHECKDIRTY AAAAAA' fn = editor.getFileName() if fn is None: fn = self.trUtf8('Noname') @@ -647,7 +646,6 @@ class ViewManager: return ok elif res == 2: return 0 - print 'CHECKDIRTY BBBBBB' return 1 def checkAllDirty(self): @@ -669,7 +667,6 @@ class ViewManager: @param editor editor window to be closed @return flag indicating success (boolean) """ - print 'CLOSEEDITOR' # save file if necessary if not self.checkDirty(editor): return 0 @@ -787,10 +784,6 @@ class ViewManager: @param caller reference to the editor calling this method """ from editor import JDCEditor - print 50*'=' - print 'newEditorView fn->',fn - print 'newEditorView caller.jdc->',caller.jdc - print 50*'+' editor = JDCEditor(fn, None, self, editor=caller) self.editors.append(editor) self.connect(editor, PYSIGNAL('modificationStatusChanged'), @@ -935,7 +928,6 @@ class ViewManager: from editor import JDCEditor editor = JDCEditor(fn, jdc, self) - print 'GETEDITOR editor.jdc->', editor.jdc if editor.jdc: # le fichier est bien un jdc self.editors.append(editor) self.connect(editor, PYSIGNAL('modificationStatusChanged'), @@ -954,10 +946,8 @@ class ViewManager: editor.closeIt() if newWin: - print 'GETEDITOR addView' self.addView(editor, fn) elif editor.jdc: - print 'GETEDITOR showView' self.showView(editor, fn) return (newWin, editor) @@ -2131,24 +2121,19 @@ class Tabview(QSplitter, ViewManager): @param win editor window to be removed """ - print 'removeView win', win for tw in self.tabWidgets: if tw.hasEditor(win): tw.removePage(win) break win.closeIt() - print 'removeView A' # if this was the last editor in this view, switch to the next, that # still has open editors - print 'removeView B' for i in range(self.tabWidgets.index(tw), -1, -1) + \ range(self.tabWidgets.index(tw) + 1, len(self.tabWidgets)): - print 'removeView C' if self.tabWidgets[i].hasEditors(): self.currentTabWidget = self.tabWidgets[i] self.activeWindow().setFocus() - print 'removeView D',self.activeWindow() break def addView(self, win, fn=None): @@ -2227,7 +2212,6 @@ class Tabview(QSplitter, ViewManager): @param m flag indicating the modification status (boolean) @param editor editor window changed """ - print 50*'handleModificationStatusChanged' for tw in self.tabWidgets: if tw.hasEditor(editor): break diff --git a/Ui/desListeParam.py b/Ui/desListeParam.py new file mode 100644 index 00000000..b2fbb269 --- /dev/null +++ b/Ui/desListeParam.py @@ -0,0 +1,42 @@ +# -*- coding: utf-8 -*- + +# Form implementation generated from reading ui file 'desListeParam.ui' +# +# Created: ven oct 19 10:25:33 2007 +# by: The PyQt User Interface Compiler (pyuic) 3.13 +# +# WARNING! All changes made in this file will be lost! + + +from qt import * + + +class DLisParam(QWidget): + def __init__(self,parent = None,name = None,fl = 0): + QWidget.__init__(self,parent,name,fl) + + if not name: + self.setName("DLisParam") + + + + self.LBParam = QListBox(self,"LBParam") + self.LBParam.setGeometry(QRect(0,0,410,390)) + + self.languageChange() + + self.resize(QSize(413,394).expandedTo(self.minimumSizeHint())) + self.clearWState(Qt.WState_Polished) + + self.connect(self.LBParam,SIGNAL("clicked(QListBoxItem*)"),self.LBParamItemPressed) + + + def languageChange(self): + self.setCaption(self.__trUtf8("\x53\xc3\xa9\x6c\x65\x63\x74\x69\x6f\x6e\x20\x64\x65\x20\x70\x61\x72\x61\x6d\xc3\xa9\x74\x72\x65\x73")) + + + def LBParamItemPressed(self): + print "DLisParam.LBParamItemPressed(): Not implemented yet" + + def __trUtf8(self,s,c = None): + return qApp.translate("DLisParam",s,c,QApplication.UnicodeUTF8) diff --git a/Ui/desListeParam.ui b/Ui/desListeParam.ui new file mode 100644 index 00000000..092d5ca0 --- /dev/null +++ b/Ui/desListeParam.ui @@ -0,0 +1,44 @@ + +DLisParam + + + DLisParam + + + + 0 + 0 + 413 + 394 + + + + Sélection de paramétres + + + + LBParam + + + + 0 + 0 + 410 + 390 + + + + + + + LBParam + clicked(QListBoxItem*) + DLisParam + LBParamItemPressed() + + + + LBParamItemPressed() + + + -- 2.39.2