You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "iDlgBase.h"
|
|
|
|
|
#include "mToolPvt_global.h"
|
|
|
|
|
|
|
|
|
|
class ZxDataPvtInfo;
|
|
|
|
|
class M_TOOL_PVT_EXPORT iWxPvtBase : public iDlgBase
|
|
|
|
|
{
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
|
|
explicit iWxPvtBase(QWidget *parent = 0);
|
|
|
|
|
~iWxPvtBase();
|
|
|
|
|
|
|
|
|
|
// 初始化
|
|
|
|
|
virtual void initUI();
|
|
|
|
|
|
|
|
|
|
// 返回数据
|
|
|
|
|
virtual bool getParaValue(QString sPara,
|
|
|
|
|
float &fValue,
|
|
|
|
|
QString sUnitDest = "");
|
|
|
|
|
|
|
|
|
|
//Pseudo
|
|
|
|
|
void setPi(float fPi);
|
|
|
|
|
float getPi();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 20220418 增加PVT的过程序列化处理
|
|
|
|
|
// 以文件方式存储,并且以Job名称为目录标识
|
|
|
|
|
virtual void setJobTag(QString sDir);
|
|
|
|
|
virtual QString getFilePvtTag(); //文件标识
|
|
|
|
|
virtual bool savePvt();
|
|
|
|
|
virtual bool loadPvt();
|
|
|
|
|
virtual QString getFilePvt(bool bLoad);
|
|
|
|
|
virtual ZxDataPvtInfo* getJobPVT(bool bLoad);
|
|
|
|
|
|
|
|
|
|
protected:
|
|
|
|
|
|
|
|
|
|
// 默认值
|
|
|
|
|
virtual void initDefault();
|
|
|
|
|
|
|
|
|
|
// 绑定参数
|
|
|
|
|
void appendParaInfos(QString sPara,
|
|
|
|
|
QWidget* pValue,
|
|
|
|
|
QWidget* pUnit,
|
|
|
|
|
float fDefault = SYS_VALUE_INVALID,
|
|
|
|
|
QString sCurUnit = "");
|
|
|
|
|
|
|
|
|
|
protected:
|
|
|
|
|
|
|
|
|
|
virtual void paintEvent(QPaintEvent*);
|
|
|
|
|
virtual void resizeEvent(QResizeEvent*);
|
|
|
|
|
|
|
|
|
|
virtual void onSerialize(ZxSerializer* ser);
|
|
|
|
|
virtual void onDeserialize(ZxSerializer* ser);
|
|
|
|
|
|
|
|
|
|
public slots:
|
|
|
|
|
void slotUnitChanged(QString s);
|
|
|
|
|
|
|
|
|
|
signals:
|
|
|
|
|
|
|
|
|
|
protected:
|
|
|
|
|
// QMap<QString, QWidget*> m_mapCtrls//借用父类
|
|
|
|
|
QMap<QString, QWidget*> m_mapUnits;
|
|
|
|
|
QMap<QString, QString> m_mapUnitDefaults; //这是算法应用的单位,而不是显示的单位
|
|
|
|
|
QMap<QString, QString> m_mapUnitLasts; //这是上一次显示的单位
|
|
|
|
|
|
|
|
|
|
//Pseudo
|
|
|
|
|
//存储Zgi、Mugi等参数
|
|
|
|
|
float m_fPi;
|
|
|
|
|
|
|
|
|
|
// 默认的存储路径,外部传递过来
|
|
|
|
|
QString m_sJobTag;
|
|
|
|
|
};
|