mirror of
https://github.com/arcan1s/awesome-widgets.git
synced 2025-07-13 22:05:48 +00:00
add tests for abstract formatter
This commit is contained in:
@ -24,9 +24,12 @@
|
||||
class AWAbstractFormatter : public AbstractExtItem
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(QString type READ type WRITE setType)
|
||||
Q_PROPERTY(FormatterClass type READ type WRITE setType)
|
||||
Q_PROPERTY(QString strType READ strType WRITE setStrType)
|
||||
|
||||
public:
|
||||
enum class FormatterClass { DateTime, Float, Script, NoFormat };
|
||||
|
||||
explicit AWAbstractFormatter(QWidget *parent,
|
||||
const QString filePath = QString());
|
||||
virtual ~AWAbstractFormatter();
|
||||
@ -34,8 +37,10 @@ public:
|
||||
void copyDefaults(AbstractExtItem *_other) const;
|
||||
QString uniq() const;
|
||||
// properties
|
||||
QString type() const;
|
||||
void setType(const QString _type = QString("NoFormat"));
|
||||
QString strType() const;
|
||||
FormatterClass type() const;
|
||||
void setStrType(const QString type);
|
||||
void setType(const FormatterClass _type = FormatterClass::NoFormat);
|
||||
|
||||
public slots:
|
||||
virtual void readConfiguration();
|
||||
@ -44,7 +49,7 @@ public slots:
|
||||
|
||||
private:
|
||||
// properties
|
||||
QString m_type = QString("NoFormat");
|
||||
FormatterClass m_type = FormatterClass::NoFormat;
|
||||
};
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user