summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPatrick McDermott <pj@pehjota.net>2017-10-12 01:22:09 (EDT)
committer Patrick McDermott <pj@pehjota.net>2017-10-12 01:27:58 (EDT)
commit5f111781ba3bfe0ec6780ebf1e36e03b8db606d1 (patch)
treeed324a9eae39f93b673d31221fea0c41cb805744 /src
parentaf920d4a01ee4a5c087595577fa96212388f9020 (diff)
downloadmarquee-5f111781ba3bfe0ec6780ebf1e36e03b8db606d1.zip
marquee-5f111781ba3bfe0ec6780ebf1e36e03b8db606d1.tar.gz
marquee-5f111781ba3bfe0ec6780ebf1e36e03b8db606d1.tar.bz2
MqTabChrome: Use mq_web_view_load_uri()
This is instead of calling webkit_web_view_load_uri() with a possibly "about:"-rewritten URI.
Diffstat (limited to 'src')
-rw-r--r--src/tab-chrome.c18
1 files changed, 2 insertions, 16 deletions
diff --git a/src/tab-chrome.c b/src/tab-chrome.c
index 3a57f4b..427d7b4 100644
--- a/src/tab-chrome.c
+++ b/src/tab-chrome.c
@@ -298,17 +298,10 @@ static void
uri_activate_cb(GtkEntry *entry, MqTabChrome *chrome)
{
const gchar *uri;
- gchar *rw_uri;
uri = gtk_entry_get_text(GTK_ENTRY(entry));
- if (g_str_has_prefix(uri, "about:")) {
- rw_uri = g_strconcat("mq-about:", uri + strlen("about:"), NULL);
- webkit_web_view_load_uri(chrome->web_view, rw_uri);
- g_free(rw_uri);
- } else {
- webkit_web_view_load_uri(chrome->web_view, uri);
- }
+ mq_web_view_load_uri(MQ_WEB_VIEW(chrome->web_view), uri);
}
static void
@@ -316,17 +309,10 @@ home_clicked_cb(GtkToolButton G_GNUC_UNUSED *toolbutton,
MqTabChrome *chrome)
{
const gchar *uri;
- gchar *rw_uri;
uri = mq_config_get_string(chrome->config, "tabs.home");
- if (g_str_has_prefix(uri, "about:")) {
- rw_uri = g_strconcat("mq-about:", uri + strlen("about:"), NULL);
- webkit_web_view_load_uri(chrome->web_view, rw_uri);
- g_free(rw_uri);
- } else {
- webkit_web_view_load_uri(chrome->web_view, uri);
- }
+ mq_web_view_load_uri(MQ_WEB_VIEW(chrome->web_view), uri);
}
static void