QT_NO_LOCALFILE_OPTIMIZED_QML should never be defined, and we don't
need to manually resolve urls coming from QML.
Change-Id: I7cdeb2814385bcb9d6004ab43686f65d388620eb
Reviewed-on: http://codereview.qt.nokia.com/3684
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Martin Jones <martin.jones@nokia.com>
if (d->progress != oldProgress)
emit progressChanged(d->progress);
} else {
-#ifndef QT_NO_LOCALFILE_OPTIMIZED_QML
QString lf = QDeclarativeEnginePrivate::urlToLocalFileOrQrc(d->url);
if (!lf.isEmpty()) {
//### should be unified with movieRequestFinished
emit progressChanged(d->progress);
return;
}
-#endif
+
d->status = Loading;
d->progress = 0;
emit statusChanged(d->status);
} else {
d->status = Loading;
if (d->url.path().endsWith(QLatin1String("sci"))) {
-#ifndef QT_NO_LOCALFILE_OPTIMIZED_QML
QString lf = QDeclarativeEnginePrivate::urlToLocalFileOrQrc(d->url);
if (!lf.isEmpty()) {
QFile file(lf);
file.open(QIODevice::ReadOnly);
setGridScaledImage(QSGGridScaledImage(&file));
- } else
-#endif
- {
+ } else {
QNetworkRequest req(d->url);
d->sciReply = qmlEngine(this)->networkAccessManager()->get(req);
Q_D(QDeclarativeFontLoader);
if (url == d->url)
return;
- d->url = qmlContext(this)->resolvedUrl(url);
+ d->url = url;
emit sourceChanged();
-#ifndef QT_NO_LOCALFILE_OPTIMIZED_QML
QString localFile = QDeclarativeEnginePrivate::urlToLocalFileOrQrc(d->url);
if (!localFile.isEmpty()) {
if (!d->fonts.contains(d->url)) {
} else {
updateFontInfo(QFontDatabase::applicationFontFamilies(d->fonts[d->url]->id).at(0), Ready);
}
- } else
-#endif
- {
+ } else {
if (!d->fonts.contains(d->url)) {
QDeclarativeFontObject *fo = new QDeclarativeFontObject;
d->fonts[d->url] = fo;