?? weapon.h
字號:
#include <QObject>#ifndef _WEAPON_H_#define _WEAPON_H_typedef enum { nil, ready, fired, exceptional}Status;class CWeapon : public QObject{ Q_OBJECT Q_PROPERTY(Status status READ getStatus WRITE setStatus) Q_ENUMS(Status)public: CWeapon(QObject *parent = 0); void setStatus(Status s); Status getStatus() const; private: Status status; Status st;};#endif
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -