Merge branch 'master' into cache-update

This commit is contained in:
itsmattkc
2022-08-18 08:12:46 -07:00
183 changed files with 7520 additions and 1705 deletions
+24
View File
@@ -208,6 +208,12 @@ public:
set_value(data);
}
template <typename T>
NodeValue(Type type, const T& data, const Node* from, const QString& tag) :
NodeValue(type, data, from, false, tag)
{
}
Type type() const
{
return type_;
@@ -238,6 +244,11 @@ public:
return tag_;
}
void set_tag(const QString& tag)
{
tag_ = tag;
}
const Node* source() const
{
return from_;
@@ -328,6 +339,7 @@ public:
QVector3D toVec3() const { return value<QVector3D>(); }
QVector4D toVec4() const { return value<QVector4D>(); }
Bezier toBezier() const { return value<Bezier>(); }
QVector<NodeValue> toArray() const { return value<QVector<NodeValue> >(); }
private:
Type type_;
@@ -375,6 +387,12 @@ public:
Push(NodeValue(type, data, from, array, tag));
}
template <typename T>
void Push(NodeValue::Type type, const T& data, const Node *from, const QString& tag)
{
Push(NodeValue(type, data, from, false, tag));
}
void Prepend(const NodeValue& value)
{
values_.prepend(value);
@@ -386,6 +404,12 @@ public:
Prepend(NodeValue(type, data, from, array, tag));
}
template <typename T>
void Prepend(NodeValue::Type type, const T& data, const Node *from, const QString& tag)
{
Prepend(NodeValue(type, data, from, false, tag));
}
const NodeValue& at(int index) const
{
return values_.at(index);