GUI: Fix bug that every error item got own parent item.

The code could not find existing parent item since items have paths
with native separators and search was done with non-native path
separators.
This commit is contained in:
Kimmo Varis 2010-07-18 13:17:21 +03:00
parent d8077cf2f7
commit c3dfe1a356
1 changed files with 3 additions and 1 deletions

View File

@ -329,7 +329,9 @@ void ResultsTree::RefreshTree()
QStandardItem *ResultsTree::EnsureFileItem(const QString &fullpath, bool hide)
{
QString name = StripPath(fullpath, false);
QStandardItem *item = FindFileItem(name);
// Since item has path with native separators we must use path with
// native separators to find it.
QStandardItem *item = FindFileItem(QDir::toNativeSeparators(name));
if (item)
{