Skip to content

Commit 4fe051a

Browse files
committed
✨ download file worker
1 parent 2c1e156 commit 4fe051a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

browsr/browsr.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
from rich.syntax import Syntax
2020
from rich.traceback import Traceback
2121
from rich_pixels import Pixels
22-
from textual import on
22+
from textual import on, work
2323
from textual.binding import Binding, BindingType
2424
from textual.containers import Container, Horizontal
2525
from textual.events import Mount
@@ -346,6 +346,7 @@ def _get_download_file_name(self) -> pathlib.Path:
346346
handled_download_path = handle_duplicate_filenames(file_path=download_path)
347347
return handled_download_path
348348

349+
@work(thread=True)
349350
def download_selected_file(self) -> None:
350351
"""
351352
Download the selected file.

0 commit comments

Comments
 (0)