Commit 4757cfa9 authored by Thomas Hartmann's avatar Thomas Hartmann
Browse files

QmlDesigner.textToModelMerger: cleanup



We do not need to support import Qt 4.7 anymore.

Change-Id: I34588117cdd54be17621a6fe102c98f105bc240e
Reviewed-by: default avatarMarco Bubke <marco.bubke@digia.com>
parent f6f59c08
......@@ -126,27 +126,6 @@ static inline QString fixEscapedUnicodeChar(const QString &value) //convert "\u2
return value;
}
static inline int fixUpMajorVersionForQt(const QString &value, int i)
{
if (i == 4 && value == "Qt")
return 1;
else return i;
}
static inline int fixUpMinorVersionForQt(const QString &value, int i)
{
if (i == 7 && value == "Qt")
return 0;
else return i;
}
static inline QString fixUpPackeNameForQt(const QString &value)
{
if (value == "Qt")
return "QtQuick";
return value;
}
static inline bool isSignalPropertyName(const QString &signalName)
{
// see QmlCompiler::isSignalPropertyName
......@@ -344,11 +323,10 @@ public:
const CppComponentValue * qmlValue = value_cast<CppComponentValue>(value);
if (qmlValue) {
typeName = fixUpPackeNameForQt(qmlValue->moduleName()) + QLatin1String(".") + qmlValue->className();
typeName = qmlValue->moduleName() + QLatin1String(".") + qmlValue->className();
//### todo this is just a hack to support QtQuick 1.0
majorVersion = fixUpMajorVersionForQt(qmlValue->moduleName(), qmlValue->componentVersion().majorVersion());
minorVersion = fixUpMinorVersionForQt(qmlValue->moduleName(), qmlValue->componentVersion().minorVersion());
majorVersion = qmlValue->componentVersion().majorVersion();
minorVersion = qmlValue->componentVersion().minorVersion();
} else {
for (UiQualifiedId *iter = astTypeNode; iter; iter = iter->next)
if (!iter->next && !iter->name.isEmpty())
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment