Compile fix (QT_NO_CAST_FROM_ASCII).

Change-Id: I4db4135758f5cec8435fe0f11ab7141068b7cee3
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
This commit is contained in:
Friedemann Kleint
2012-11-28 12:34:02 +01:00
parent 5ea0937167
commit e3d3cf987c
2 changed files with 2 additions and 2 deletions

View File

@@ -127,7 +127,7 @@ bool SimpleAbstractStreamReader::readFile(const QString &fileName)
if (file.open(QIODevice::ReadOnly)) {
QByteArray source = file.readAll();
file.close();
return readFromSource(source);
return readFromSource(QString::fromLocal8Bit(source));
}
addError(tr("Cannot find file %1").arg(fileName));
return false;

View File

@@ -106,7 +106,7 @@ QmlConsoleView::QmlConsoleView(QWidget *parent) :
#if defined(Q_OS_UNIX) && !defined(Q_OS_MAC)
if (baseName == QLatin1String("windows")) {
// Sometimes we get the standard windows 95 style as a fallback
if (QStyleFactory::keys().contains("Fusion"))
if (QStyleFactory::keys().contains(QLatin1String("Fusion")))
baseName = QLatin1String("fusion"); // Qt5
else { // Qt4
// e.g. if we are running on a KDE4 desktop