diff options
author | Christian Persch <chpe@src.gnome.org> | 2003-09-02 07:20:17 +0800 |
---|---|---|
committer | Christian Persch <chpe@src.gnome.org> | 2003-09-02 07:20:17 +0800 |
commit | 73a95385f4034998cc78199dc8bb9ee22d90d6aa (patch) | |
tree | 499d78ab52e8937f672e3659105dda083a34c988 /embed/ephy-embed-single.c | |
parent | 3375c1878c4c0ebf4f5067d128024ea484208f62 (diff) | |
download | gsoc2013-epiphany-73a95385f4034998cc78199dc8bb9ee22d90d6aa.tar gsoc2013-epiphany-73a95385f4034998cc78199dc8bb9ee22d90d6aa.tar.gz gsoc2013-epiphany-73a95385f4034998cc78199dc8bb9ee22d90d6aa.tar.bz2 gsoc2013-epiphany-73a95385f4034998cc78199dc8bb9ee22d90d6aa.tar.lz gsoc2013-epiphany-73a95385f4034998cc78199dc8bb9ee22d90d6aa.tar.xz gsoc2013-epiphany-73a95385f4034998cc78199dc8bb9ee22d90d6aa.tar.zst gsoc2013-epiphany-73a95385f4034998cc78199dc8bb9ee22d90d6aa.zip |
Mega-patch, changelog too long to paste here.
Diffstat (limited to 'embed/ephy-embed-single.c')
-rw-r--r-- | embed/ephy-embed-single.c | 33 |
1 files changed, 9 insertions, 24 deletions
diff --git a/embed/ephy-embed-single.c b/embed/ephy-embed-single.c index 66f6da6ee..fe42ba07b 100644 --- a/embed/ephy-embed-single.c +++ b/embed/ephy-embed-single.c @@ -14,6 +14,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + * $Id$ */ #include <config.h> @@ -33,11 +35,13 @@ enum LAST_SIGNAL }; + +#define EPHY_EMBED_SINGLE_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), EPHY_TYPE_EMBED_SINGLE, EphyEmbedSinglePrivate)) + struct EphyEmbedSinglePrivate { EphyHistory *global_history; DownloaderView *downloader_view; - GList *embeds; EphyFaviconCache *favicon_cache; }; @@ -45,10 +49,9 @@ static void ephy_embed_single_class_init (EphyEmbedSingleClass *klass); static void ephy_embed_single_init (EphyEmbedSingle *ges); -static void -ephy_embed_single_finalize (GObject *object); static GObjectClass *parent_class = NULL; + static guint ephy_embed_single_signals[LAST_SIGNAL] = { 0 }; GType @@ -86,8 +89,6 @@ ephy_embed_single_class_init (EphyEmbedSingleClass *klass) parent_class = (GObjectClass *) g_type_class_peek_parent (klass); - object_class->finalize = ephy_embed_single_finalize; - ephy_embed_single_signals[NEW_WINDOW] = g_signal_new ("new_window_orphan", G_OBJECT_CLASS_TYPE (object_class), @@ -99,37 +100,21 @@ ephy_embed_single_class_init (EphyEmbedSingleClass *klass) 2, G_TYPE_POINTER, G_TYPE_INT); + + g_type_class_add_private (object_class, sizeof(EphyEmbedSinglePrivate)); } static void ephy_embed_single_init (EphyEmbedSingle *ges) { - ges->priv = g_new0 (EphyEmbedSinglePrivate, 1); + ges->priv = EPHY_EMBED_SINGLE_GET_PRIVATE (ges); ges->priv->global_history = NULL; ges->priv->downloader_view = NULL; - ges->priv->embeds = NULL; ges->priv->favicon_cache = NULL; } -static void -ephy_embed_single_finalize (GObject *object) -{ - EphyEmbedSingle *ges; - - g_return_if_fail (object != NULL); - g_return_if_fail (IS_EPHY_EMBED_SINGLE (object)); - - ges = EPHY_EMBED_SINGLE (object); - - g_return_if_fail (ges->priv != NULL); - - g_free (ges->priv); - - G_OBJECT_CLASS (parent_class)->finalize (object); -} - gresult ephy_embed_single_clear_cache (EphyEmbedSingle *shell) { |