#include "CFDStructDataSolverBasicModelManager.h" #include "CUIProperty/CUIConfig.h" CFDStructDataSolverBasicModelManager::CFDStructDataSolverBasicModelManager(QObject *parent) : CFDStructDataManagerBase(parent) { m_uiConfig = nullptr; } CFDStructDataSolverBasicModelManager::~CFDStructDataSolverBasicModelManager() { if (m_uiConfig != nullptr) { delete m_uiConfig; m_uiConfig = nullptr; } } CUIConfig *CFDStructDataSolverBasicModelManager::getParamUIConfig() { return this->genFluidPropertiesOnUIConfig(); } /** * @param 求解器中,基本模型,流体属性关闭时的属性界面设置 * * @return 属性设置 */ CUIConfig *CFDStructDataSolverBasicModelManager::genFluidPropertiesOffUIConfig() { return new CUIConfig({ {"type", "Widget"}, }, {new CUIConfig({ // 下拉框:求解器类型 {"type", "ComboBox"}, {"name", tr("Solver Type")}, }, {new CUIConfig({ {"type", "Item"}, {"name", tr("Compressible Flow")} // 选项:可压缩流动 })}), new CUIConfig({// 下拉框:流动模型 {"type", "ComboBox"}, {"name", tr("Flow Model")}}, {new CUIConfig({// 选项:外流 {"type", "Item"}, {"name", tr("Internal Flow")}}), new CUIConfig({// 选项:内流 {"type", "Item"}, {"name", tr("External Flow")}}), new CUIConfig({// 选项:多级叶轮机械 {"type", "Item"}, {"name", tr("Multistage Turbomachinery")}})}), new CUIConfig({// 方形勾选:重叠网络 {"type", "CheckBox"}, {"name", tr("Overlay Network")}}), new CUIConfig({// 圆形选择按钮:流体属性 {"type", "RadioButton"}, {"name", tr("Fluid Properties")}})}); } CUIConfig *CFDStructDataSolverBasicModelManager::genFluidPropertiesOnUIConfig() { return new CUIConfig({ {"type", "Widget"}, }, {new CUIConfig({ // 下拉框:求解器类型 {"type", "ComboBox"}, {"name", tr("Solver Type")}, }, {new CUIConfig({ {"type", "Item"}, {"name", tr("Compressible Flow")} // 选项:可压缩流动 })}), new CUIConfig({// 下拉框:流动模型 {"type", "ComboBox"}, {"name", tr("Flow Model")}}, {new CUIConfig({// 选项:外流 {"type", "Item"}, {"name", tr("Internal Flow")}}), new CUIConfig({// 选项:内流 {"type", "Item"}, {"name", tr("External Flow")}}), new CUIConfig({// 选项:多级叶轮机械 {"type", "Item"}, {"name", tr("Multistage Turbomachinery")}})}), new CUIConfig({// 方形勾选:重叠网络 {"type", "CheckBox"}, {"name", tr("ichimr")}}), new CUIConfig({// 圆形选择按钮:流体属性 {"type", "RadioButton"}, {"name", tr("Fluid Properties")}}), new CUIConfig({// 组,流体属性下的内容 {"type", "GroupBox"}, {"name", tr("Fluid Properties")}}, { new CUIConfig({// 气体成分 {"type", "LineEdit"}, {"name", tr("Gas Composition")}}), new CUIConfig({// 气体常数 {"type", "LineEdit"}, {"name", tr("rgasmean")}}), new CUIConfig({// 比热比 {"type", "LineEdit"}, {"name", tr("gmean")}}), new CUIConfig({// 层流普朗特数 {"type", "LineEdit"}, {"name", tr("prlmean")}}), new CUIConfig({// 湍流普朗特数 {"type", "LineEdit"}, {"name", tr("prtmean")}}), })}); }