本文整理汇总了Python中code_saturne.Base.QtPage.ComboModel.getItems方法的典型用法代码示例。如果您正苦于以下问题:Python ComboModel.getItems方法的具体用法?Python ComboModel.getItems怎么用?Python ComboModel.getItems使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类code_saturne.Base.QtPage.ComboModel
的用法示例。
在下文中一共展示了ComboModel.getItems方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: FluidCharacteristicsView
# 需要导入模块: from code_saturne.Base.QtPage import ComboModel [as 别名]
# 或者: from code_saturne.Base.QtPage.ComboModel import getItems [as 别名]
#.........这里部分代码省略.........
if tag == 'volume_viscosity':
__combo.setEnabled(True)
c = self.mdl.getPropertyMode(tag)
if c == 'variable':
__button.setEnabled(True)
else:
__button.setEnabled(False)
self.groupBoxViscv0.show()
else:
if tag == 'specific_heat':
self.groupBoxCp.setTitle('Specific heat')
self.case.undoStartGlobal()
def updateTypeChoice(self):
"""
add/suppress thermo tables for each proprties
"""
for tag, symbol in self.lst:
__model = getattr(self, "model" + symbol)
if self.mdl.getMaterials() == "user_material":
__model.disableItem(str_model='thermal_law')
else:
__model.enableItem(str_model='thermal_law')
c = self.mdl.getPropertyMode(tag)
__model.setItem(str_model=c)
def updateMethod(self):
"""
update method list with material choice
"""
for nb in range(len(self.modelMethod.getItems())):
self.modelMethod.delItem(0)
self.comboBoxPhas.hide()
self.labelPhas.hide()
if self.mdl.getMaterials() == "user_material":
self.modelMethod.addItem(self.tr('user properties'), 'user_properties')
else :
if EOS == 1:
material = self.mdl.getMaterials()
self.ava.setMethods(material)
fls = self.ava.whichMethods()
for fli in fls:
self.modelMethod.addItem(self.tr(fli),fli)
if self.mdl.getMethod() != "freesteam":
self.comboBoxPhas.show()
self.labelPhas.show()
if self.freesteam == 1 and self.mdl.getMaterials() == "Water":
self.modelMethod.addItem(self.tr("freesteam"), "freesteam")
# update comboBoxMethod
method = self.mdl.getMethod()
self.modelMethod.setItem(str_model=method)
self.updateReference()
def updateReference(self):
"""
update Reference with material, method and field nature choice
"""
# update lineEditReference