Skip to content

Commit

Permalink
Update directory_tree.py fixed single click
Browse files Browse the repository at this point in the history
single click now expands folder without needing to click on arrow
  • Loading branch information
celltoolz authored Jun 22, 2024
1 parent f165183 commit 60ec0da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion porcupine/plugins/directory_tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ def _on_click(self, event: tkinter.Event[DirectoryTree]) -> str | None:

little_arrow_clicked = self.identify_element(event.x, event.y) == "Treeitem.indicator"

if little_arrow_clicked:
if little_arrow_clicked or not item.startswith("file"):
self.item(item, open=(not self.item(item, "open")))
if self.item(item, "open"):
self.open_file_or_dir()
Expand Down

0 comments on commit 60ec0da

Please sign in to comment.