summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichel Ludwig <michel.ludwig@kdemail.net>2015-07-21 19:25:16 (GMT)
committerMichel Ludwig <michel.ludwig@kdemail.net>2015-07-21 19:29:14 (GMT)
commitf98eb936d51142408999173290797601573be407 (patch)
tree76dd35289871498bd161b4d697f703d37118ea8b
parent991e11e81b9d3d48f45c021527b5f9bd0b38dffb (diff)
Fix url creation in 'Document::processSourceReference'
This commit fixes the error message "<url> is not a local file" when processing source references. 'giveAbsolutePath(QString)' returns a local file name, so we create the corresponding url using 'QUrl::fromLocalFile'.
-rw-r--r--core/document.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/document.cpp b/core/document.cpp
index 665844b..a066174 100644
--- a/core/document.cpp
+++ b/core/document.cpp
@@ -4011,7 +4011,7 @@ void Document::processSourceReference( const SourceReference * ref )
if ( !ref )
return;
- const QUrl url( d->giveAbsolutePath( ref->fileName() ) );
+ const QUrl url = QUrl::fromLocalFile( d->giveAbsolutePath( ref->fileName() ) );
if ( !url.isLocalFile() )
{
qCDebug(OkularCoreDebug) << url.url() << "is not a local file.";