#pragma once #include "iDlgBase.h" #include "iGuiGridPty_global.h" // 这是内部嵌套用的QDateTimeEdit class X_GUI_GRIDPTY_EXPORT QDateTimeEditEx : public QDateTimeEdit { Q_OBJECT public: QDateTimeEditEx(QWidget *parent = 0); ~QDateTimeEditEx(); void setActive(bool b); bool isActive(); signals: void sigActivated(bool); protected: virtual void focusInEvent(QFocusEvent *e); virtual void focusOutEvent(QFocusEvent *e); private: bool m_bActive; };