aboutsummaryrefslogtreecommitdiffstats
path: root/embed
diff options
context:
space:
mode:
Diffstat (limited to 'embed')
-rw-r--r--embed/ephy-history.c17
-rw-r--r--embed/ephy-history.h6
2 files changed, 18 insertions, 5 deletions
diff --git a/embed/ephy-history.c b/embed/ephy-history.c
index 197ad85d3..1c4cb3b28 100644
--- a/embed/ephy-history.c
+++ b/embed/ephy-history.c
@@ -536,19 +536,28 @@ ephy_history_host_visited (EphyHistory *eh,
static EphyNode *
ephy_history_add_host (EphyHistory *eh, EphyNode *page)
{
+ const char *url;
+
+ url = ephy_node_get_property_string
+ (page, EPHY_NODE_PAGE_PROP_LOCATION);
+
+ return ephy_history_get_host (eh, url);
+}
+
+EphyNode *
+ephy_history_get_host (EphyHistory *eh, const char *url)
+{
GnomeVFSURI *vfs_uri = NULL;
EphyNode *host = NULL;
const char *host_name = NULL;
GList *host_locations = NULL, *l;
GValue value = { 0, };
- const char *url;
const char *scheme = NULL;
GTime now;
- now = time (NULL);
+ g_return_val_if_fail (url != NULL, NULL);
- url = ephy_node_get_property_string
- (page, EPHY_NODE_PAGE_PROP_LOCATION);
+ now = time (NULL);
vfs_uri = gnome_vfs_uri_new (url);
diff --git a/embed/ephy-history.h b/embed/ephy-history.h
index 80565aba7..52948b65c 100644
--- a/embed/ephy-history.h
+++ b/embed/ephy-history.h
@@ -45,7 +45,8 @@ enum
EPHY_NODE_PAGE_PROP_FIRST_VISIT = 6,
EPHY_NODE_PAGE_PROP_HOST_ID = 7,
EPHY_NODE_PAGE_PROP_PRIORITY = 8,
- EPHY_NODE_PAGE_PROP_ICON = 9
+ EPHY_NODE_PAGE_PROP_ICON = 9,
+ EPHY_NODE_HOST_PROP_ZOOM = 10
};
struct EphyHistory
@@ -67,6 +68,9 @@ EphyHistory *ephy_history_new (void);
EphyNode *ephy_history_get_hosts (EphyHistory *gh);
+EphyNode *ephy_history_get_host (EphyHistory *gh,
+ const char *url);
+
EphyNode *ephy_history_get_pages (EphyHistory *gh);
EphyNode *ephy_history_get_page (EphyHistory *gh,