diff options
author | Xan Lopez <xan@src.gnome.org> | 2007-10-26 04:00:48 +0800 |
---|---|---|
committer | Xan Lopez <xan@src.gnome.org> | 2007-10-26 04:00:48 +0800 |
commit | 2be1a6942311c3f8fd0d9335820919d281b437db (patch) | |
tree | e050677a298de872b4870c6a1ee8e88267aa954c /embed/ephy-embed.c | |
parent | 929c43cd4cadadb2d1ddc26fd2d0500867d9ea75 (diff) | |
download | gsoc2013-epiphany-2be1a6942311c3f8fd0d9335820919d281b437db.tar gsoc2013-epiphany-2be1a6942311c3f8fd0d9335820919d281b437db.tar.gz gsoc2013-epiphany-2be1a6942311c3f8fd0d9335820919d281b437db.tar.bz2 gsoc2013-epiphany-2be1a6942311c3f8fd0d9335820919d281b437db.tar.lz gsoc2013-epiphany-2be1a6942311c3f8fd0d9335820919d281b437db.tar.xz gsoc2013-epiphany-2be1a6942311c3f8fd0d9335820919d281b437db.tar.zst gsoc2013-epiphany-2be1a6942311c3f8fd0d9335820919d281b437db.zip |
Move icon and icon-address to EphyEmbed.
There's a snippet that needs to be moved elsewhere I think:
eb = ephy_shell_get_bookmarks (ephy_shell);
ephy_bookmarks_set_icon (eb, priv->address,
priv->icon_address);
It's done in mozilla_embed_set_icon_address.
svn path=/trunk/; revision=7561
Diffstat (limited to 'embed/ephy-embed.c')
-rw-r--r-- | embed/ephy-embed.c | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/embed/ephy-embed.c b/embed/ephy-embed.c index 882c9bfd6..0a822ee11 100644 --- a/embed/ephy-embed.c +++ b/embed/ephy-embed.c @@ -497,6 +497,19 @@ ephy_embed_base_init (gpointer g_class) "The embed's link message", NULL, G_PARAM_READABLE | G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB)); + g_object_interface_install_property (g_class, + g_param_spec_object ("icon", + "Icon", + "The embed icon's", + GDK_TYPE_PIXBUF, + G_PARAM_READABLE | G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB)); + + g_object_interface_install_property (g_class, + g_param_spec_string ("icon-address", + "Icon address", + "The embed icon's address", + NULL, + (G_PARAM_READWRITE | G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB))); initialized = TRUE; } @@ -1229,3 +1242,34 @@ ephy_embed_get_status_message (EphyEmbed *embed) return iface->get_status_message (embed); } +/** + * ephy_embed_get_icon: + * @embed: an #EphyEmbed + * + * Returns the embed's site icon as a #GdkPixbuf, + * or %NULL if it is not available. + * + * Return value: a the embed's site icon + **/ +GdkPixbuf * +ephy_embed_get_icon (EphyEmbed *embed) +{ + EphyEmbedIface *iface = EPHY_EMBED_GET_IFACE (embed); + return iface->get_icon (embed); +} + +/** + * ephy_embed_get_icon_address: + * @embed: an #EphyEmbed + * + * Returns a URL which points to @embed's site icon. + * + * Return value: the URL of @embed's site icon + **/ +const char * +ephy_embed_get_icon_address (EphyEmbed *embed) +{ + EphyEmbedIface *iface = EPHY_EMBED_GET_IFACE (embed); + return iface->get_icon_address (embed); +} + |