TypeDescriptionReader: Check for files that are not UTF8 encoded

We had a qmltypes file that was encoded in UTF16 and did not work.
We should at least warn about it.

Change-Id: I42555782ee16ddd25552f919845aa85ff1f3f636
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
This commit is contained in:
Thomas Hartmann
2013-05-15 11:11:32 +02:00
parent 3604bdbad2
commit 7d25b90908
3 changed files with 24 additions and 9 deletions

View File

@@ -608,10 +608,9 @@ public:
static BuiltinObjects defaultLibraryObjects;
// parses the contents of a qmltypes file and fills the newObjects map
static void parseQmlTypeDescriptions(
const QByteArray &qmlTypes,
static void parseQmlTypeDescriptions(const QByteArray &contents,
BuiltinObjects *newObjects,
QList<ModuleApiInfo> *newModuleApis, QString *errorMessage, QString *warningMessage);
QList<ModuleApiInfo> *newModuleApis, QString *errorMessage, QString *warningMessage, const QString &fileName);
};
class QMLJS_EXPORT CppQmlTypes