[Commits] [SCM] claws branch, master, updated. 4.2.0-104-g44b1b201e
paul at claws-mail.org
paul at claws-mail.org
Wed Jun 5 11:17:15 UTC 2024
The branch, master has been updated
via 44b1b201e4017d924776c29eb8e86c15bf49a3d9 (commit)
from fab3c79304dcafc24845e41a403305cf32a6e411 (commit)
Summary of changes:
src/compose.c | 16 +++++++++++++---
src/prefs_common.c | 5 +++--
src/prefs_common.h | 3 ++-
3 files changed, 18 insertions(+), 6 deletions(-)
- Log -----------------------------------------------------------------
commit 44b1b201e4017d924776c29eb8e86c15bf49a3d9
Author: Paul <paul at claws-mail.org>
Date: Wed Jun 5 12:17:11 2024 +0100
allow hiding the Notice panel when pasting files into the Compose window
diff --git a/src/compose.c b/src/compose.c
index 7e9ae673a..e15df0edc 100644
--- a/src/compose.c
+++ b/src/compose.c
@@ -10975,11 +10975,21 @@ static void attach_uri_list(Compose *compose, GtkSelectionData *data)
g_free(utf8_filename);
}
if (list) {
+ AlertValue val;
compose_changed_cb(NULL, compose);
- alertpanel_notice(ngettext(
- "The following file has been attached: \n%s",
- "The following files have been attached: \n%s", att), warn_files);
+ if (prefs_common.notify_pasted_attachments) {
+ gchar *msg;
+
+ msg = g_strdup_printf(ngettext("The following file has been attached: \n%s",
+ "The following files have been attached: \n%s", att), warn_files);
+ val = alertpanel_full(_("Notice"), msg,
+ NULL, _("_Close"), NULL, NULL, NULL, NULL,
+ ALERTFOCUS_FIRST, TRUE, NULL, ALERT_NOTICE);
+ g_free(msg);
+ }
g_free(warn_files);
+ if (val & G_ALERTDISABLE)
+ prefs_common.notify_pasted_attachments = FALSE;
}
list_free_strings_full(list);
}
diff --git a/src/prefs_common.c b/src/prefs_common.c
index 4de16db40..f0a359d36 100644
--- a/src/prefs_common.c
+++ b/src/prefs_common.c
@@ -1,6 +1,6 @@
/*
* Claws Mail -- a GTK based, lightweight, and fast e-mail client
- * Copyright (C) 1999-2023 the Claws Mail team and Hiroyuki Yamamoto
+ * Copyright (C) 1999-2024 the Claws Mail team and Hiroyuki Yamamoto
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -241,7 +241,8 @@ static PrefParam param[] = {
NULL, NULL, NULL},
{"type_any_header", "FALSE", &prefs_common.type_any_header, P_BOOL,
NULL, NULL, NULL},
-
+ {"notify_pasted_attachments", "TRUE", &prefs_common.notify_pasted_attachments, P_BOOL,
+ NULL, NULL, NULL},
{"linewrap_length", "72", &prefs_common.linewrap_len, P_INT,
NULL, NULL, NULL},
diff --git a/src/prefs_common.h b/src/prefs_common.h
index 30e15c424..ad0cfce4c 100644
--- a/src/prefs_common.h
+++ b/src/prefs_common.h
@@ -1,6 +1,6 @@
/*
* Claws Mail -- a GTK based, lightweight, and fast e-mail client
- * Copyright (C) 1999-2023 the Claws Mail team and Hiroyuki Yamamoto
+ * Copyright (C) 1999-2024 the Claws Mail team and Hiroyuki Yamamoto
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -205,6 +205,7 @@ struct _PrefsCommon
gchar *compose_body_format;
gboolean show_compose_margin;
gboolean type_any_header;
+ gboolean notify_pasted_attachments;
/* Quote */
gboolean reply_with_quote;
-----------------------------------------------------------------------
hooks/post-receive
--
Claws Mail
More information about the Commits
mailing list