mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
fix the bug where a filter is applied in friends file list even if view mode is tree and search box is hidden. Problem was: SharedFilesDialog::FilterItems() is called from multiple places. The check if we should filter or not is now in the filter function itself.
This commit is contained in:
parent
a118870db9
commit
b125cb1f1e
@ -363,10 +363,7 @@ void SharedFilesDialog::changeCurrentViewModel(int viewTypeIndex)
|
||||
|
||||
ui.dirTreeView->header()->headerDataChanged(Qt::Horizontal, COLUMN_NAME, COLUMN_DIR) ;
|
||||
|
||||
#ifdef DONT_USE_SEARCH_IN_TREE_VIEW
|
||||
if(viewTypeIndex == VIEW_TYPE_FLAT)
|
||||
#endif
|
||||
FilterItems();
|
||||
FilterItems();
|
||||
}
|
||||
|
||||
void LocalSharedFilesDialog::showProperColumns()
|
||||
@ -1017,6 +1014,11 @@ void SharedFilesDialog::startFilter()
|
||||
|
||||
void SharedFilesDialog::FilterItems()
|
||||
{
|
||||
#ifdef DONT_USE_SEARCH_IN_TREE_VIEW
|
||||
if(proxyModel == tree_proxyModel)
|
||||
return;
|
||||
#endif
|
||||
|
||||
QString text = ui.filterPatternLineEdit->text();
|
||||
|
||||
setCursor(Qt::WaitCursor);
|
||||
|
Loading…
Reference in New Issue
Block a user