Add 0KiB File Preview max download file size
Description of the new feature
Currently Gajim has a file preview system that allows to limit the maximum file size for downloads. The allowed values range from 256Kib
to 10MiB
. In Conversations, users are allowed to specify Never
to disable automatic download, and manually download images:
This functionality can be particularly useful in workplaces, where a user might still want to have preview enabled but have the ability to manually download files.
Patch
GitLab isn't allowing me to fork and make a merge request, but the proposed enhancement is contained in the following patch:
From 40b9d88f43291524d4fd97e6c39b96cf0b7456b4 Mon Sep 17 00:00:00 2001
From: clouded <minus@clouded.monster>
Date: Sun, 29 Jan 2023 13:18:35 +0100
Subject: [PATCH] imprv: Preferences: FilePreview sizes 0KiB
---
gajim/gtk/preferences.py | 1 +
1 file changed, 1 insertion(+)
diff --git a/gajim/gtk/preferences.py b/gajim/gtk/preferences.py
index 76255e691..c51e71798 100644
--- a/gajim/gtk/preferences.py
+++ b/gajim/gtk/preferences.py
@@ -392,6 +392,7 @@ def _reset_print_status(button: Gtk.Button) -> None:
class FilePreview(PreferenceBox):
def __init__(self, *args: Any) -> None:
sizes = {
+ 0: '0 KiB',
262144: '256 KiB',
524288: '512 KiB',
1048576: '1 MiB',
--
2.39.0
Thank you for your time.