#ifndef ONEPARAMITEM_H #define ONEPARAMITEM_H #include #include "spdlog/spdlog.h" #include "EyeMapInfo.h" namespace Ui { class OneParamItem; } class OneParamItem : public QWidget { Q_OBJECT public: explicit OneParamItem(QWidget *parent = nullptr); ~OneParamItem(); /* 设置信息 */ void setInfo(const OneEyeMapInfo &info); protected: /* 事件过滤器 */ bool eventFilter(QObject *watched, QEvent *event) override; private slots: /* 选择了电压值 */ void do_selectVoltage(int index); private: /* 根据输入的枚举值获取字符串 */ QString getVoltageRangeStr(OscVoltageRange range); public: OneEyeMapInfo eyeMapInfo; private: Ui::OneParamItem *ui; std::shared_ptr m_logger = nullptr; }; #endif // ONEPARAMITEM_H