summaryrefslogtreecommitdiff
path: root/qutebrowser/mainwindow
diff options
context:
space:
mode:
authorJason Rosenzweig <mail4jasonr@gmail.com>2021-06-04 01:20:49 +0800
committerJason Rosenzweig <mail4jasonr@gmail.com>2021-06-04 01:20:49 +0800
commit1fe3ba356e4243581fa3ee308287560bff7ccab4 (patch)
tree2f02c1c064ac431cbf31831f88fa045e22a55773 /qutebrowser/mainwindow
parent0a87bb71cc4ceb3426bab82bc23da24c9cfabada (diff)
downloadqutebrowser-1fe3ba356e4243581fa3ee308287560bff7ccab4.tar.gz
qutebrowser-1fe3ba356e4243581fa3ee308287560bff7ccab4.zip
Better tests, added back _get_valid_dirs hopefully temporarily
Diffstat (limited to 'qutebrowser/mainwindow')
-rw-r--r--qutebrowser/mainwindow/prompt.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/qutebrowser/mainwindow/prompt.py b/qutebrowser/mainwindow/prompt.py
index 182b58b40..3e6ffba01 100644
--- a/qutebrowser/mainwindow/prompt.py
+++ b/qutebrowser/mainwindow/prompt.py
@@ -738,16 +738,17 @@ class FilenamePrompt(_BasePrompt):
hidden = self._to_complete not in index.data()
if not hidden:
dirs.append(index.data())
+ # self._file_view.setRowHidden(index.row(), index.parent(), hidden)
except FileNotFoundError:
log.prompt.debug("Directory doesn't exist, can't \
get valid dirs")
-
+
return dirs
def _do_completion(self, idx, which):
filename = self._file_model.fileName(idx)
valid_dirs = self._get_valid_dirs(self._current_path)
- while idx.isValid() and not self._file_view.isRowHidden(idx.row(), idx.parent()):
+ while not filename in valid_dirs and idx.isValid():
if which == 'prev':
idx = self._file_view.indexAbove(idx)
else: