aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/util/qquickglobal.cpp
diff options
context:
space:
mode:
authorUlf Hermann <[email protected]>2020-09-16 12:59:31 +0200
committerUlf Hermann <[email protected]>2020-09-16 14:55:27 +0200
commitae9bef00159fa3362309ccf3a9999f75bd45e81e (patch)
treeece223ac23956d44421579cd87e7b439ceba5220 /src/quick/util/qquickglobal.cpp
parent876408197b0b2fc8e11e82d318b8ea420206880e (diff)
QQmlValueTypeProvider: Remove dead code
The more adventurous variant/string conversions are luckily unused. Let's remove them before anyone gets ideas. Change-Id: I6f95cbdf9ead12ab723cafdbb2b0f02a0ff461fa Reviewed-by: Maximilian Goldstein <[email protected]> Reviewed-by: Lars Knoll <[email protected]>
Diffstat (limited to 'src/quick/util/qquickglobal.cpp')
-rw-r--r--src/quick/util/qquickglobal.cpp54
1 files changed, 0 insertions, 54 deletions
diff --git a/src/quick/util/qquickglobal.cpp b/src/quick/util/qquickglobal.cpp
index 4d5b8e4a1c..e6000e352a 100644
--- a/src/quick/util/qquickglobal.cpp
+++ b/src/quick/util/qquickglobal.cpp
@@ -730,60 +730,6 @@ public:
return false;
}
- bool createStringFrom(int type, const void *data, QString *s) override
- {
- if (type == QMetaType::QColor) {
- const QColor *color = reinterpret_cast<const QColor *>(data);
- new (s) QString(QVariant(*color).toString());
- return true;
- }
-
- return false;
- }
-
- bool variantFromString(const QString &s, QVariant *v) override
- {
- QColor c(s);
- if (c.isValid()) {
- *v = QVariant::fromValue(c);
- return true;
- }
-
- bool ok = false;
-
- QVector2D v2 = vector2DFromString(s, &ok);
- if (ok) {
- *v = QVariant::fromValue(v2);
- return true;
- }
-
- QVector3D v3 = vector3DFromString(s, &ok);
- if (ok) {
- *v = QVariant::fromValue(v3);
- return true;
- }
-
- QVector4D v4 = vector4DFromString(s, &ok);
- if (ok) {
- *v = QVariant::fromValue(v4);
- return true;
- }
-
- QQuaternion q = quaternionFromString(s, &ok);
- if (ok) {
- *v = QVariant::fromValue(q);
- return true;
- }
-
- QMatrix4x4 m = matrix4x4FromString(s, &ok);
- if (ok) {
- *v = QVariant::fromValue(m);
- return true;
- }
-
- return false;
- }
-
bool variantFromString(int type, const QString &s, QVariant *v) override
{
bool ok = false;