[Commits] [SCM] clawsker branch, master, updated. 1.2.0-10-g68d1d19

mones at claws-mail.org mones at claws-mail.org
Sat Nov 10 19:35:38 CET 2018


The branch, master has been updated
       via  68d1d199ee753dacc0b58a4cddde97d7960f86de (commit)
      from  81c8d99f9f131e00475f9b1d9e069288aac8be31 (commit)

Summary of changes:
 clawsker |   30 +++++++++++++++---------------
 1 file changed, 15 insertions(+), 15 deletions(-)


- Log -----------------------------------------------------------------
commit 68d1d199ee753dacc0b58a4cddde97d7960f86de
Author: Ricardo Mones <ricardo at mones.org>
Date:   Sat Nov 10 19:33:23 2018 +0100

    Fix missing new_with_markup in MessageDialog
    
    Error was “Can't locate object method "new_with_markup" via package
    "Gtk3::MessageDialog" at /usr/lib/x86_64-linux-gnu/perl5/5.24/Glib.pm
    line 222.”
    
    See: https://developer.gnome.org/gtk3/stable/GtkMessageDialog.html#gtk-message-dialog-new-with-markup

diff --git a/clawsker b/clawsker
index 01735b3..9d09671 100755
--- a/clawsker
+++ b/clawsker
@@ -453,7 +453,8 @@ sub log_message {
 sub error_dialog {
     my ($emsg) = @_;
     my $markup = "<span weight=\"bold\" size=\"large\">" . $emsg . "</span>";
-    my $errordlg = Gtk3::MessageDialog->new_with_markup ($main_window, 'modal', 'error', 'cancel', $markup);
+    my $errordlg = Gtk3::MessageDialog->new ($main_window, 'modal', 'error', 'cancel');
+    $errordlg->set_markup ($markup);
     $errordlg->set_title (_('Clawsker error'));
     $errordlg->run;
     $errordlg->destroy;
@@ -2749,15 +2750,15 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.";
     my $holder = "Ricardo Mones <ricardo\@mones.org>";
     my $url = "http://www.claws-mail.org/clawsker.php";
 
-    my $dialog = Gtk3::MessageDialog->new_with_markup ($parent,
-                    [qw/modal destroy-with-parent/],
-                    'info', 'close',
-                    "<span size=\"x-large\" weight=\"bold\">$title</span>\n"
-                    . "<span size=\"large\">$vers</span>\n\n"
-                    . "<span color=\"blue\" size=\"large\">$url</span>\n\n"
-                    . "<span>Copyright $year by $holder</span>\n\n"
-                    . "<span size=\"large\">$lic</span>\n\n"
-                    . "<span size=\"small\">$license</span>");
+    my $dialog = Gtk3::MessageDialog->new ($parent,
+        [qw/modal destroy-with-parent/], 'info', 'close');
+    $dialog->set_markup (
+        "<span size=\"x-large\" weight=\"bold\">$title</span>\n"
+        . "<span size=\"large\">$vers</span>\n\n"
+        . "<span color=\"blue\" size=\"large\">$url</span>\n\n"
+        . "<span>Copyright $year by $holder</span>\n\n"
+        . "<span size=\"large\">$lic</span>\n\n"
+        . "<span size=\"small\">$license</span>");
     $dialog->set_title ($xl::s{about});
     if (Gtk3->CHECK_VERSION (2, 10, 0)) {
         my @icons = get_app_icons ();
@@ -2775,11 +2776,10 @@ sub exit_handler {
   if ($MODIFIED != 0 and not $READONLY) {
     my $fact = $xl::s{exit_fact};
     my $question = $xl::s{exit_question};
-    my $dialog = Gtk3::MessageDialog->new_with_markup ($parent,
-                    [qw/modal destroy-with-parent/],
-                    'warning', 'yes-no',
-                    "<span>$fact</span>\n\n"
-                    . "<span weight=\"bold\">$question</span>");
+    my $dialog = Gtk3::MessageDialog->new ($parent,
+        [qw/modal destroy-with-parent/], 'warning', 'yes-no');
+    $dialog->set_markup ("<span>$fact</span>\n\n"
+        . "<span weight=\"bold\">$question</span>");
     $dialog->set_title ($xl::s{exit_title});
     my $resp = $dialog->run;
     $dialog->hide;

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


hooks/post-receive
-- 
Hidden preferences editor for Claws Mail


More information about the Commits mailing list