This repository has been archived on 2024-07-22. You can view files and clone it, but cannot push or open issues or pull requests.
Doric/doric-Qt/doric/shader/DoricViewNode.h

39 lines
621 B
C
Raw Normal View History

2021-02-08 11:37:51 +08:00
#ifndef DORICVIEWNODE_H
#define DORICVIEWNODE_H
2021-02-19 10:04:54 +08:00
#include <QQuickItem>
2021-02-09 15:54:22 +08:00
2021-02-08 11:37:51 +08:00
#include "../utils/DoricContextHolder.h"
class DoricSuperNode;
2021-02-08 11:37:51 +08:00
class DoricViewNode : public DoricContextHolder {
2021-02-09 15:54:22 +08:00
protected:
2021-02-19 10:04:54 +08:00
QQuickItem *mView;
2021-02-09 15:54:22 +08:00
DoricSuperNode *mSuperNode;
2021-02-19 10:04:54 +08:00
virtual QQuickItem *build() = 0;
2021-02-09 15:54:22 +08:00
virtual void blendLayoutConfig();
void setLayoutConfig(QJSValue layoutConfig);
2021-02-09 15:54:22 +08:00
private:
QString mId;
QString mType;
2021-02-08 11:37:51 +08:00
public:
using DoricContextHolder::DoricContextHolder;
void init(DoricSuperNode *superNode);
QString getId();
void setId(QString id);
void blend(QJSValue jsValue);
2021-02-08 11:37:51 +08:00
};
#endif // DORICVIEWNODE_H