aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorClaudio Saavedra <csaavedra@igalia.com>2012-03-07 22:47:02 +0800
committerClaudio Saavedra <csaavedra@igalia.com>2012-03-08 00:14:10 +0800
commit50715d718d83a09c1bbe76b99002b72c359a5754 (patch)
tree3fb23894b86d6609d5e684a793bae85df914f6a5 /src
parent5596d5fb76a9d39ad3ea78e613ad9058a5ed948c (diff)
downloadgsoc2013-epiphany-50715d718d83a09c1bbe76b99002b72c359a5754.tar.gz
gsoc2013-epiphany-50715d718d83a09c1bbe76b99002b72c359a5754.tar.zst
gsoc2013-epiphany-50715d718d83a09c1bbe76b99002b72c359a5754.zip
ephy-history-window: update the list of hosts after a url is deleted
Since now we remove orphan hosts, we need to update the list of hosts after url removal, too. Do this while preserving the currently selected host, if any. https://bugzilla.gnome.org/show_bug.cgi?id=671559
Diffstat (limited to 'src')
-rw-r--r--src/ephy-history-window.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/ephy-history-window.c b/src/ephy-history-window.c
index 461a06450..90f18b1f1 100644
--- a/src/ephy-history-window.c
+++ b/src/ephy-history-window.c
@@ -436,7 +436,7 @@ on_browse_history_deleted_cb (gpointer service,
if (success != TRUE)
return;
- filter_now (editor, FALSE, TRUE);
+ filter_now (editor, TRUE, TRUE);
}
static void
@@ -1029,15 +1029,21 @@ on_get_hosts_cb (gpointer service,
gpointer user_data)
{
EphyHistoryWindow *window = EPHY_HISTORY_WINDOW (user_data);
+ EphyHistoryHost *selected_host;
GList *hosts;
if (success != TRUE)
goto out;
hosts = (GList *) result_data;
+ selected_host = get_selected_host (window);
gtk_list_store_clear (GTK_LIST_STORE (window->priv->hosts_store));
ephy_hosts_store_add_hosts (window->priv->hosts_store, hosts);
-
+ if (selected_host) {
+ ephy_hosts_view_select_host (EPHY_HOSTS_VIEW (window->priv->hosts_view),
+ selected_host);
+ ephy_history_host_free (selected_host);
+ }
out:
g_list_free_full (hosts, (GDestroyNotify)ephy_history_host_free);
}