Re: Debuggin by environment variable instead of compile time. Was: GIT version - no display of html messages
Albrecht Dreß <[email protected]>
| Newsgroups | gmane.comp.gnome.apps.balsa |
|---|---|
| Message-ID | <[email protected]> |
Am 07.07.18 21:01 schrieb(en) Albrecht Dreß: > Am 07.07.18 20:49 schrieb(en) Peter Bloomfield: >> Albrecht has been making that change in various places, using g_debug() instead of various printing calls. I've just done the same in the HTML code, so you can run Balsa with: >> >> G_MESSAGES_DEBUG=html src/balsa > > Ooops, looks as if we had the same idea at the same time… …and attached is a new patch for libbalsa/html.c, on top of your changes, fixing the HTML rendering issue. Also defines the html log domain only if we have html rendering. It would be cool if you could add the changes to README (from the 1st one), so we have it documented. Thanks Albrecht. _______________________________________________ balsa-list mailing list [email protected] https://mail.gnome.org/mailman/listinfo/balsa-list
fix_old_webkit_2.diff
(text/x-patch, 1000 B)
diff --git a/libbalsa/html.c b/libbalsa/html.c
index 1e5e2f500..307194e0a 100644
--- a/libbalsa/html.c
+++ b/libbalsa/html.c
@@ -44,13 +44,13 @@
#include <string.h>
#include <glib/gi18n.h>
+#ifdef HAVE_HTML_WIDGET
+
#ifdef G_LOG_DOMAIN
# undef G_LOG_DOMAIN
#endif
#define G_LOG_DOMAIN "html"
-#ifdef HAVE_HTML_WIDGET
-
/*
* Used by all HTML widgets
*
@@ -281,8 +281,12 @@ lbh_navigation_policy_decision(WebKitPolicyDecision * decision,
g_debug("%s clicked %s", __func__, uri);
(*info->clicked_cb) (uri);
default:
- g_debug("%s uri %s, type %d, ignored", __func__, uri, navigation_type);
- webkit_policy_decision_ignore(decision);
+ if (g_ascii_strcasecmp(uri, "about:blank") != 0) {
+ g_debug("%s uri %s, type %d, ignored", __func__, uri, navigation_type);
+ webkit_policy_decision_ignore(decision);
+ } else {
+ g_debug("%s uri %s, type %d loaded", __func__, uri, navigation_type);
+ }
}
}
signature.asc
(application/pgp-signature, 488 B)
-----BEGIN PGP SIGNATURE----- iQEzBAABCAAdFiEEcCEPemLFTtyGf4zATKlvDmfn2fgFAltBF9MACgkQTKlvDmfn 2fi1zwgAh0wWfMOh/UbdkqE0at5plSB22wRJBLxwI0BkX0momFOzxzHzw1sXHJ2G Yquy2BdJRPzsf8zRkMO4emHx4EZ8y5TYg62CbxMWW7EYt7tzYatIypXDUR7sdBIb NXlhyeIwYXBHqWsfTMPrqtGeCaw3Dv0OfTu94QA/lBgkg1iUv0XIzauu9rvKBs2D MXa3LsDKJbUsQ8X8MpimwdRoGI5+xY2msOllQWeQqbt4Yd9RuoUt6ALLjItqH6u3 ypaMb8WVK20zWSjGsLql2/ZsBOEzTCPgxKxlmC7cU5po0g60PNGtid4FzA6M7rW+ +W/V8aKxhkG30KNkHeDhcRr9gCrbSA== =tk8x -----END PGP SIGNATURE-----