From f1b7a657670fa07f30bbb376e307a0392743d71a Mon Sep 17 00:00:00 2001 From: Peter Stockings Date: Tue, 24 Mar 2026 10:56:00 +1100 Subject: [PATCH] fix: use file extension in QFileDialog filter to prevent space corruption --- desktop-client/main.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/desktop-client/main.py b/desktop-client/main.py index b4afe28..d9a2080 100644 --- a/desktop-client/main.py +++ b/desktop-client/main.py @@ -149,8 +149,10 @@ class VlcSyncApp(QMainWindow): QMessageBox.information(self, "File Required", f"To join this room, you need to select:\n\nName: {req_name}\nSize: {req_size / (1024*1024):.1f} MB") + ext = os.path.splitext(req_name)[1].lower() + file_filter = f"Video Files (*{ext});;All Files (*)" if ext else "All Files (*)" file_path, _ = QFileDialog.getOpenFileName( - self, f"Select {req_name}", "", f"Required File ({req_name})" + self, f"Select {req_name}", "", file_filter ) if file_path: