[Commits] [SCM] claws branch, gtk3, updated. 4.0.0-397-g3d221d4dd

miras at claws-mail.org miras at claws-mail.org
Mon Jan 3 13:29:41 UTC 2022


The branch, gtk3 has been updated
       via  3d221d4ddc651ae8dd2285133d7891d35c43a504 (commit)
      from  3b2fc511f130933391dc32312d2cf6c8dbfe41a8 (commit)

Summary of changes:
 src/compose.c | 16 +---------------
 1 file changed, 1 insertion(+), 15 deletions(-)


- Log -----------------------------------------------------------------
commit 3d221d4ddc651ae8dd2285133d7891d35c43a504
Author: Michael Rasmussen <mir at datanom.net>
Date:   Mon Jan 3 14:29:33 2022 +0100

    Use internal function alertpanel_error instead of gtk_message_dialog
    
    Signed-off-by: Michael Rasmussen <mir at datanom.net>

diff --git a/src/compose.c b/src/compose.c
index 2a2560cf0..fab624670 100644
--- a/src/compose.c
+++ b/src/compose.c
@@ -10873,20 +10873,6 @@ static void entry_copy_clipboard(GtkWidget *entry)
 			gtk_clipboard_get(GDK_SELECTION_CLIPBOARD));
 }
 
-static void text_too_big_alert(Compose *compose, glong size) {
-        GtkDialogFlags flags = GTK_DIALOG_DESTROY_WITH_PARENT;
-        GtkMessageDialog* dialog = gtk_message_dialog_new(
-                                        GTK_WINDOW(compose->window),
-                                        flags,
-                                        GTK_MESSAGE_INFO,
-                                        GTK_BUTTONS_OK,
-                                        _("Number of pages '%d' exceeds limit '%d' for paste. Attach as file instead"),
-                                        (size / 1800),
-                                        (MAX_ALLOCA_MEM_SIZE / 1800));
-        gtk_dialog_run(GTK_DIALOG(dialog));
-        gtk_widget_destroy(GTK_WIDGET(dialog));
-}
-
 static void entry_paste_clipboard(Compose *compose, GtkWidget *entry, 
  				  gboolean wrap, GdkAtom clip, GtkTextIter *insert_place)
 {
@@ -10902,7 +10888,7 @@ static void entry_paste_clipboard(Compose *compose, GtkWidget *entry,
 
                 glong len = g_utf8_strlen(contents, -1);
                 if (len > MAX_ALLOCA_MEM_SIZE) {
-                        text_too_big_alert(compose, len);
+                        alertpanel_error(_("Number of pages '%d' exceeds limit '%d' for paste.\nAttach as file instead."), (len / 1800), (MAX_ALLOCA_MEM_SIZE / 1800));
                         return;
                 }
 		/* we shouldn't delete the selection when middle-click-pasting, or we

-----------------------------------------------------------------------


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list