From: David Faure Date: Fri, 6 Jul 2007 13:36:04 +0000 (+0000) Subject: simplify + add todo (early commit to make room for the next kdebase-wide commit) X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/commitdiff_plain/0661c42dd9893c67a7ceaea6585df2cf7aa3a440 simplify + add todo (early commit to make room for the next kdebase-wide commit) svn path=/trunk/KDE/kdebase/apps/; revision=684300 --- diff --git a/src/dolphinview.cpp b/src/dolphinview.cpp index 042c74b2c..4895f199c 100644 --- a/src/dolphinview.cpp +++ b/src/dolphinview.cpp @@ -465,18 +465,11 @@ void DolphinView::triggerItem(const QModelIndex& index) return; } - // Prefer the local path over the URL. This assures that the - // volume space information is correct. Assuming that the URL is media:/sda1, - // and the local path is /windows/C: For the URL the space info is related - // to the root partition (and hence wrong) and for the local path the space - // info is related to the windows partition (-> correct). - const QString localPath(item->localPath()); - KUrl url; - if (localPath.isEmpty()) { - url = item->url(); - } else { - url = localPath; - } + // The stuff below should be moved to ViewContainer and be just a signal? + + // Prefer the local path over the URL. + bool isLocal; + KUrl url = item->mostLocalUrl(isLocal); if (item->isDir()) { setUrl(url);