mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
Have the reset method take part in background loading
One instance of a call to _load_directory that I missed.
This commit is contained in:
@@ -135,7 +135,7 @@ class DirectoryTree(Tree[DirEntry]):
|
||||
def reload(self) -> None:
|
||||
"""Reload the `DirectoryTree` contents."""
|
||||
self.reset(str(self.path), DirEntry(Path(self.path)))
|
||||
self._load_directory(self.root)
|
||||
self._add_load_job(self.root)
|
||||
|
||||
def validate_path(self, path: str | Path) -> Path:
|
||||
"""Ensure that the path is of the `Path` type.
|
||||
|
||||
Reference in New Issue
Block a user