mirror of
https://bitbucket.org/smil3y/kde-extraapps.git
synced 2025-02-24 02:42:52 +00:00
kdeplasma-addons: log epod POTD provider URL
currently broken, when the URL (https://epod.usra.edu/.a/6a0105371bb32c970b02b751a11620200c-pi) is opened in chromium the picture is a small white square. go figure Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
f881924974
commit
4cc0def5c3
2 changed files with 3 additions and 3 deletions
|
@ -60,7 +60,8 @@ void EpodProvider::Private::pageRequestFinished(KJob *_job)
|
||||||
|
|
||||||
int pos = exp.indexIn( data ) + pattern.length();
|
int pos = exp.indexIn( data ) + pattern.length();
|
||||||
const QString sub = data.mid( pos-4, pattern.length()+5);
|
const QString sub = data.mid( pos-4, pattern.length()+5);
|
||||||
KUrl url( QString(QLatin1String( "https://epod.usra.edu/.a/%1-pi" )) .arg(sub) );
|
KUrl url( QString::fromLatin1("https://epod.usra.edu/.a/%1-pi" ) .arg(sub) );
|
||||||
|
kDebug() << "url" << url.prettyUrl();
|
||||||
KIO::StoredTransferJob *imageJob = KIO::storedGet( url, KIO::NoReload, KIO::HideProgressInfo );
|
KIO::StoredTransferJob *imageJob = KIO::storedGet( url, KIO::NoReload, KIO::HideProgressInfo );
|
||||||
QObject::connect(imageJob, SIGNAL(finished(KJob*)), mParent, SLOT(imageRequestFinished(KJob*)) );
|
QObject::connect(imageJob, SIGNAL(finished(KJob*)), mParent, SLOT(imageRequestFinished(KJob*)) );
|
||||||
}
|
}
|
||||||
|
@ -73,7 +74,6 @@ void EpodProvider::Private::imageRequestFinished( KJob *_job)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FIXME: this really should be done in a thread as this can block
|
|
||||||
mImage = QImage::fromData( job->data() );
|
mImage = QImage::fromData( job->data() );
|
||||||
emit mParent->finished( mParent );
|
emit mParent->finished( mParent );
|
||||||
}
|
}
|
||||||
|
|
|
@ -101,7 +101,7 @@ void FlickrProvider::Private::pageRequestFinished( KJob *_job )
|
||||||
}
|
}
|
||||||
|
|
||||||
if (xml.error() && xml.error() != QXmlStreamReader::PrematureEndOfDocumentError) {
|
if (xml.error() && xml.error() != QXmlStreamReader::PrematureEndOfDocumentError) {
|
||||||
qWarning() << "XML ERROR:" << xml.lineNumber() << ": " << xml.errorString();
|
kWarning() << "XML error" << xml.lineNumber() << ": " << xml.errorString();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_photoList.begin() != m_photoList.end()) {
|
if (m_photoList.begin() != m_photoList.end()) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue