[Commits] [SCM] claws branch, master, updated. 4.3.0-27-g2319aaaf6
paul at claws-mail.org
paul at claws-mail.org
Tue Aug 13 11:24:41 UTC 2024
The branch, master has been updated
via 2319aaaf6f28c88c2d04a2b1afd8366363dfc73b (commit)
from 09953e4005573c130e48edab594c2de95d23dadb (commit)
Summary of changes:
src/gtk/inputdialog.c | 32 +++++++++++++++++++++-----------
src/prefs_common.c | 3 +++
src/prefs_common.h | 4 +++-
3 files changed, 27 insertions(+), 12 deletions(-)
- Log -----------------------------------------------------------------
commit 2319aaaf6f28c88c2d04a2b1afd8366363dfc73b
Author: Paul <paul at claws-mail.org>
Date: Tue Aug 13 12:24:37 2024 +0100
add hidden pref, passphrase_dialog_msg_title_switch, which switches the message and title placement in the passphrase dialog
implements RFE 4821, 'Add more information to server password dialog's title for KeePassXC'
diff --git a/src/gtk/inputdialog.c b/src/gtk/inputdialog.c
index 83f28c4f8..aa2d51f2a 100644
--- a/src/gtk/inputdialog.c
+++ b/src/gtk/inputdialog.c
@@ -1,6 +1,6 @@
/*
* Claws Mail -- a GTK based, lightweight, and fast e-mail client
- * Copyright (C) 1999-2021 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
@@ -122,7 +122,10 @@ gchar *input_dialog_with_invisible(const gchar *title, const gchar *message,
is_pass = TRUE;
gtk_entry_set_visibility(GTK_ENTRY(entry), FALSE);
- return input_dialog_open(title, message, NULL, default_string, FALSE, NULL);
+ if (prefs_common.passphrase_dialog_msg_title_switch)
+ return input_dialog_open(message, title, NULL, default_string, FALSE, NULL);
+ else
+ return input_dialog_open(title, message, NULL, default_string, FALSE, NULL);
}
gchar *input_dialog_with_invisible_checkbtn(const gchar *title, const gchar *message,
@@ -152,7 +155,14 @@ gchar *input_dialog_with_invisible_checkbtn(const gchar *title, const gchar *mes
is_pass = TRUE;
gtk_entry_set_visibility(GTK_ENTRY(entry), FALSE);
- return input_dialog_open(title, message, checkbtn_label, default_string, (checkbtn_state? *checkbtn_state:FALSE), checkbtn_state);
+ if (prefs_common.passphrase_dialog_msg_title_switch)
+ return input_dialog_open(message, title, checkbtn_label,
+ default_string, (checkbtn_state? *checkbtn_state:FALSE),
+ checkbtn_state);
+ else
+ return input_dialog_open(title, message, checkbtn_label,
+ default_string, (checkbtn_state? *checkbtn_state:FALSE),
+ checkbtn_state);
}
gchar *input_dialog_combo(const gchar *title, const gchar *message,
@@ -224,16 +234,16 @@ gchar *input_dialog_query_password(const gchar *server, const gchar *user)
gchar *pass;
if (server && user)
- message = g_strdup_printf(_("Input password for %s on %s:"),
+ message = g_strdup_printf(_("Input password for %s on %s"),
user, server);
else if (server)
- message = g_strdup_printf(_("Input password for %s:"),
+ message = g_strdup_printf(_("Input password for %s"),
server);
else if (user)
- message = g_strdup_printf(_("Input password for %s:"),
+ message = g_strdup_printf(_("Input password for %s"),
user);
else
- message = g_strdup_printf(_("Input password:"));
+ message = g_strdup_printf(_("Input password"));
pass = input_dialog_with_invisible(_("Input password"), message, NULL);
g_free(message);
@@ -246,16 +256,16 @@ gchar *input_dialog_query_password_keep(const gchar *server, const gchar *user,
gchar *pass;
if (server && user)
- message = g_strdup_printf(_("Input password for %s on %s:"),
+ message = g_strdup_printf(_("Input password for %s on %s"),
user, server);
else if (server)
- message = g_strdup_printf(_("Input password for %s:"),
+ message = g_strdup_printf(_("Input password for %s"),
server);
else if (user)
- message = g_strdup_printf(_("Input password for %s:"),
+ message = g_strdup_printf(_("Input password for %s"),
user);
else
- message = g_strdup_printf(_("Input password:"));
+ message = g_strdup_printf(_("Input password"));
if (keep) {
if (*keep != NULL) {
pass = g_strdup (*keep);
diff --git a/src/prefs_common.c b/src/prefs_common.c
index 47bc3f93b..d2347274c 100644
--- a/src/prefs_common.c
+++ b/src/prefs_common.c
@@ -1320,6 +1320,9 @@ static PrefParam param[] = {
{"qs_press_timeout", "500", &prefs_common.qs_press_timeout, P_INT,
NULL, NULL, NULL},
+ {"passphrase_dialog_msg_title_switch", "FALSE", &prefs_common.passphrase_dialog_msg_title_switch,
+ P_BOOL, NULL, NULL, NULL},
+
{NULL, NULL, NULL, P_OTHER, NULL, NULL, NULL}
};
diff --git a/src/prefs_common.h b/src/prefs_common.h
index 6c81f1c4a..bb1feb893 100644
--- a/src/prefs_common.h
+++ b/src/prefs_common.h
@@ -590,6 +590,8 @@ struct _PrefsCommon
guint primary_passphrase_pbkdf2_rounds;
#endif
+ gboolean passphrase_dialog_msg_title_switch;
+
/* Proxy */
gboolean use_proxy;
ProxyInfo proxy_info;
@@ -603,7 +605,7 @@ extern PrefsCommon prefs_common;
PrefsCommon *prefs_common_get_prefs(void);
GList *prefs_common_read_history_from_dir_with_defaults(const gchar *dirname, const gchar *history,
- GList *default_list);
+ GList *default_list);
void prefs_common_read_config (void);
void prefs_common_write_config (void);
void prefs_common_open (void);
-----------------------------------------------------------------------
hooks/post-receive
--
Claws Mail
More information about the Commits
mailing list