43QQmlScriptString QQmlScriptStringPrivate::create(
const QString &script, QQmlContext *context,
46 return QQmlScriptString(script, context, scope);
60QQmlScriptString::QQmlScriptString(
const QString &script, QQmlContext *context, QObject *scope)
97bool QQmlScriptString::operator==(
const QQmlScriptString &other)
const
104 if (d->isNumberLiteral || other.d->isNumberLiteral)
105 return d->isNumberLiteral && other.d->isNumberLiteral && d->numberValue == other.d->numberValue;
107 if (d->isStringLiteral || other.d->isStringLiteral)
108 return d->isStringLiteral && other.d->isStringLiteral && d->script == other.d->script;
110 if (d->script == QLatin1String(
"true") ||
111 d->script == QLatin1String(
"false") ||
112 d->script == QLatin1String(
"undefined") ||
113 d->script == QLatin1String(
"null"))
114 return d->script == other.d->script;
116 return d->context == other.d->context &&
117 d->scope == other.d->scope &&
118 d->script == other.d->script &&
119 d->bindingId == other.d->bindingId;