diff options
author | Michael Brasser <michael.brasser@nokia.com> | 2010-05-18 04:51:58 (GMT) |
---|---|---|
committer | Michael Brasser <michael.brasser@nokia.com> | 2010-05-18 05:07:44 (GMT) |
commit | 3d1a6596c6a381b71718af22eb8a861830ec7b6b (patch) | |
tree | 9e7be18bdb1358c6c460a12a19653922c0409352 /src/declarative/qml/qdeclarativeparser_p.h | |
parent | 690ad58e03fb064e90e2e66e96419d82d9ee343d (diff) | |
download | Qt-3d1a6596c6a381b71718af22eb8a861830ec7b6b.zip Qt-3d1a6596c6a381b71718af22eb8a861830ec7b6b.tar.gz Qt-3d1a6596c6a381b71718af22eb8a861830ec7b6b.tar.bz2 |
Make sure strings are escaped when returned via asScript.
Makes 273024e58d90bb9b3a5da0161f884f1af22d75df more correct.
Diffstat (limited to 'src/declarative/qml/qdeclarativeparser_p.h')
-rw-r--r-- | src/declarative/qml/qdeclarativeparser_p.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/declarative/qml/qdeclarativeparser_p.h b/src/declarative/qml/qdeclarativeparser_p.h index 25777f5..d192f3a 100644 --- a/src/declarative/qml/qdeclarativeparser_p.h +++ b/src/declarative/qml/qdeclarativeparser_p.h @@ -307,8 +307,8 @@ namespace QDeclarativeParser }; Type type; - // ### Temporary - QString primitive() const { return value.asScript(); } + // ### Temporary (for id only) + QString primitive() const { return value.isString() ? value.asString() : value.asScript(); } // Primitive value Variant value; |