Summary: | dolphin (kde-4.8rc2) does not synchronize folderview on the left with opened folder on the right in some cases | ||
---|---|---|---|
Product: | [Applications] dolphin | Reporter: | H.H. <cyberbeat> |
Component: | panels: folders | Assignee: | Peter Penz <peter.penz19> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | frank78ac, gedgon |
Priority: | NOR | Keywords: | investigated |
Version: | 2.0 | ||
Target Milestone: | --- | ||
Platform: | Unlisted Binaries | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 4.8.1 | |
Sentry Crash Report: |
Description
H.H.
2012-01-17 15:08:36 UTC
Thanks for the bug report! I can confirm the problem. The problem is in void KFileItemModel::setExpanded(const QSet<KUrl>& urls). This function contains the line const QStringList subDirs = url.url().mid(pos).split(QDir::separator()); to determine a chain of sub folders leading to the url to be expanded. However, KUrl::url() returns a QString where special characters like spaces are encoded -> "xxx xxx" becomes "xxx%2520xxx". The expansion algorithm in KFileItemModel::slotCompleted() then fails to find the encoded url in the model. So we should transform the KUrl to a QString without encoding it. I'll have a look at that later. *** Bug 290721 has been marked as a duplicate of this bug. *** Git commit 80d9bfec580bf01b0ee584fc4bb46e3d59a0ba7c by Frank Reininghaus. Committed on 25/01/2012 at 21:30. Pushed by freininghaus into branch 'KDE/4.8'. Handle folder names containing spaces correctly in the Folders Panel The problem was that KFileItemModel::setExpanded() used KUrl::url() to determine the names of the subfolders. This method encodes special characters, such that comparing the folder names with the unencoded URLs stored in the model fails. Using KUrl::path(), which does not encode special characters, fixes the problem. FIXED-IN: 4.8.1 M +2 -2 dolphin/src/kitemviews/kfileitemmodel.cpp http://commits.kde.org/kde-baseapps/80d9bfec580bf01b0ee584fc4bb46e3d59a0ba7c Git commit e6e8e6fdc1a4d50364b9479b1de7d8fc3b5c0c64 by Frank Reininghaus. Committed on 25/01/2012 at 21:30. Pushed by freininghaus into branch 'master'. Handle folder names containing spaces correctly in the Folders Panel The problem was that KFileItemModel::setExpanded() used KUrl::url() to determine the names of the subfolders. This method encodes special characters, such that comparing the folder names with the unencoded URLs stored in the model fails. Using KUrl::path(), which does not encode special characters, fixes the problem. FIXED-IN: 4.8.1 (cherry picked from commit 80d9bfec580bf01b0ee584fc4bb46e3d59a0ba7c) M +2 -2 dolphin/src/kitemviews/kfileitemmodel.cpp http://commits.kde.org/kde-baseapps/e6e8e6fdc1a4d50364b9479b1de7d8fc3b5c0c64 |