From 44a2351b72f7fd702c4b68c59943c50937632cc4 Mon Sep 17 00:00:00 2001 From: Alexander Butenko Date: Wed, 21 Jul 2010 10:35:47 -0400 Subject: [PATCH] Decode URIs before updating the locationbar --- midori/midori-browser.c | 4 +--- midori/midori-locationaction.c | 8 +++++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/midori/midori-browser.c b/midori/midori-browser.c index c5043f2e..42d61e09 100644 --- a/midori/midori-browser.c +++ b/midori/midori-browser.c @@ -609,9 +609,7 @@ midori_view_notify_title_cb (GtkWidget* widget, uri = midori_view_get_display_uri (view); title = midori_view_get_display_title (view); action = _action_by_name (browser, "Location"); - if (browser->maximum_history_age) - midori_location_action_set_title_for_uri ( - MIDORI_LOCATION_ACTION (action), title, uri); + if (midori_view_get_load_status (view) == MIDORI_LOAD_COMMITTED) { KatzeItem* item; diff --git a/midori/midori-locationaction.c b/midori/midori-locationaction.c index de70b2c0..2ec6034b 100644 --- a/midori/midori-locationaction.c +++ b/midori/midori-locationaction.c @@ -1445,12 +1445,14 @@ void midori_location_action_set_uri (MidoriLocationAction* location_action, const gchar* uri) { + gchar* escaped_uri; + g_return_if_fail (MIDORI_IS_LOCATION_ACTION (location_action)); g_return_if_fail (uri != NULL); - katze_assign (location_action->uri, g_uri_unescape_string (uri, "")); - - midori_location_action_set_text (location_action, uri); + escaped_uri = g_uri_unescape_string (uri, ""); + midori_location_action_set_text (location_action, escaped_uri); + g_free (escaped_uri); } /** -- 2.39.5