diff --git a/core/bookmarkmanager.cpp b/core/bookmarkmanager.cpp index d63ae75d7..4223741bd 100644 --- a/core/bookmarkmanager.cpp +++ b/core/bookmarkmanager.cpp @@ -106,7 +106,7 @@ QString BookmarkManager::Private::currentUrl() const QString BookmarkManager::Private::currentTitle() const { - return url.isLocalFile() ? url.path() : url.prettyUrl(); + return url.isLocalFile() ? url.toLocalFile() : url.prettyUrl(); } bool BookmarkManager::Private::enableOption(BookmarkOption option) const @@ -241,7 +241,7 @@ QHash::iterator BookmarkManager::Private::bookmarkFind( const KUr { // folder not found :( // then, in a single step create a new folder and add it in our cache :) - QString purl = url.isLocalFile() ? url.path() : url.prettyUrl(); + QString purl = url.isLocalFile() ? url.toLocalFile() : url.prettyUrl(); KBookmarkGroup newbg = root.createNewFolder( purl ); it = knownFiles.insert( url, newbg.address() ); if ( result ) diff --git a/part.cpp b/part.cpp index 57cf92278..f58c30d35 100644 --- a/part.cpp +++ b/part.cpp @@ -879,7 +879,7 @@ bool Part::slotImportPSFile() m_temporaryLocalFile = tf.fileName(); tf.close(); - setLocalFilePath( url.path() ); + setLocalFilePath( url.toLocalFile() ); QStringList args; QProcess *p = new QProcess(); args << url.toLocalFile() << m_temporaryLocalFile; diff --git a/ui/bookmarklist.cpp b/ui/bookmarklist.cpp index dd88e6b2c..3bfdd58d6 100644 --- a/ui/bookmarklist.cpp +++ b/ui/bookmarklist.cpp @@ -290,7 +290,7 @@ void BookmarkList::rebuildTree( bool filter ) if ( !subitems.isEmpty() ) { QTreeWidgetItem * item = new QTreeWidgetItem( m_tree, FileItemType ); - QString fileString = url.isLocalFile() ? url.path() : url.prettyUrl(); + QString fileString = url.isLocalFile() ? url.toLocalFile() : url.prettyUrl(); item->setText( 0, fileString ); item->setToolTip( 0, i18ncp( "%1 is the file name", "%1\n\nOne bookmark", "%1\n\n%2 bookmarks", fileString, subitems.count() ) ); item->setData( 0, UrlRole, qVariantFromValue( url ) ); @@ -350,7 +350,7 @@ void BookmarkList::selectiveUrlUpdate( const KUrl& url, QTreeWidgetItem*& item ) } else { - const QString fileString = url.isLocalFile() ? url.path() : url.prettyUrl(); + const QString fileString = url.isLocalFile() ? url.toLocalFile() : url.prettyUrl(); if ( item ) { for ( int i = item->childCount() - 1; i >= 0; --i ) diff --git a/ui/formwidgets.cpp b/ui/formwidgets.cpp index 84968e8d2..96dfaf117 100644 --- a/ui/formwidgets.cpp +++ b/ui/formwidgets.cpp @@ -358,7 +358,7 @@ FileEdit::FileEdit( Okular::FormFieldText * text, QWidget * parent ) void FileEdit::slotChanged( const QString& ) { - m_form->setText( url().path() ); + m_form->setText( url().toLocalFile() ); m_controller->signalChanged( this ); }