[epiphany-extensions] Adapt sidebar extension to new API.
- From: Xan Lopez <xan src gnome org>
- To: svn-commits-list gnome org
- Subject: [epiphany-extensions] Adapt sidebar extension to new API.
- Date: Tue, 23 Jun 2009 03:34:00 -0400 (EDT)
commit a256011076e0213c6edaa63f76d53c4511b57d24
Author: Xan Lopez <xan gnome org>
Date: Tue Jun 23 10:17:05 2009 +0300
Adapt sidebar extension to new API.
extensions/sidebar/ephy-sidebar-embed.c | 12 +++++++-----
extensions/sidebar/sidebar-commands.c | 12 ++++++------
2 files changed, 13 insertions(+), 11 deletions(-)
---
diff --git a/extensions/sidebar/ephy-sidebar-embed.c b/extensions/sidebar/ephy-sidebar-embed.c
index 2a12844..e9a0f52 100644
--- a/extensions/sidebar/ephy-sidebar-embed.c
+++ b/extensions/sidebar/ephy-sidebar-embed.c
@@ -295,8 +295,8 @@ save_property_url (EphyEmbed *embed,
value = ephy_embed_event_get_property (event, property);
location = g_value_get_string (value);
- persist = EPHY_EMBED_PERSIST
- (ephy_embed_factory_new_object (EPHY_TYPE_EMBED_PERSIST));
+ persist = EPHY_EMBED_PERSIST
+ (g_object_new (EPHY_TYPE_EMBED_PERSIST, NULL));
ephy_embed_persist_set_embed (persist, embed);
ephy_embed_persist_set_flags (persist, 0);
@@ -397,19 +397,20 @@ ephy_sidebar_embed_create_embed (EphySidebarEmbed *sbembed)
{
EphyEmbed *embed;
- embed = EPHY_EMBED(ephy_embed_factory_new_object (EPHY_TYPE_EMBED));
+ embed = g_object_new (EPHY_TYPE_EMBED, NULL);
gtk_container_add (GTK_CONTAINER (sbembed), GTK_WIDGET (embed));
gtk_widget_show (GTK_WIDGET (embed));
if (sbembed->priv->url == NULL)
{
- ephy_embed_load_url (embed, "about:blank");
+ ephy_web_view_load_url (EPHY_GET_EPHY_WEB_VIEW_FROM_EMBED (embed), "about:blank");
}
else
{
- ephy_embed_load_url (embed, sbembed->priv->url);
+ ephy_web_view_load_url (EPHY_GET_EPHY_WEB_VIEW_FROM_EMBED (embed), sbembed->priv->url);
+ /* FIXME: this signals are not emitted right now
g_signal_connect (G_OBJECT (embed),
"ge_dom_mouse_click",
G_CALLBACK(embed_mouse_click_cb),
@@ -418,6 +419,7 @@ ephy_sidebar_embed_create_embed (EphySidebarEmbed *sbembed)
"ge_context_menu",
G_CALLBACK(embed_contextmenu_cb),
sbembed);
+ */
}
}
diff --git a/extensions/sidebar/sidebar-commands.c b/extensions/sidebar/sidebar-commands.c
index 09fab7f..4edfea3 100644
--- a/extensions/sidebar/sidebar-commands.c
+++ b/extensions/sidebar/sidebar-commands.c
@@ -48,8 +48,8 @@ sidebar_cmd_file_save_as (GtkAction *action,
window = ephy_sidebar_embed_get_window (sidebar);
- persist = EPHY_EMBED_PERSIST
- (ephy_embed_factory_new_object (EPHY_TYPE_EMBED_PERSIST));
+ persist = EPHY_EMBED_PERSIST
+ (g_object_new (EPHY_TYPE_EMBED_PERSIST, NULL));
ephy_embed_persist_set_embed (persist, embed);
ephy_embed_persist_set_fc_title (persist, _("Save As"));
@@ -89,8 +89,8 @@ save_property_url (GtkAction *action,
value = ephy_embed_event_get_property (event, property);
location = g_value_get_string (value);
- persist = EPHY_EMBED_PERSIST
- (ephy_embed_factory_new_object (EPHY_TYPE_EMBED_PERSIST));
+ persist = EPHY_EMBED_PERSIST
+ (g_object_new (EPHY_TYPE_EMBED_PERSIST, NULL));
ephy_embed_persist_set_embed (persist, embed);
ephy_embed_persist_set_fc_title (persist, title);
@@ -124,9 +124,9 @@ sidebar_cmd_open_frame (GtkAction *action,
embed = ephy_sidebar_embed_get_embed (sidebar);
g_return_if_fail (embed != NULL);
- location = ephy_embed_get_location (embed, FALSE);
+ location = ephy_web_view_get_location (EPHY_GET_EPHY_WEB_VIEW_FROM_EMBED (embed), FALSE);
- ephy_embed_load_url (embed, location);
+ ephy_web_view_load_url (EPHY_GET_EPHY_WEB_VIEW_FROM_EMBED (embed), location);
g_free (location);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]