aboutsummaryrefslogtreecommitdiffstats
path: root/src/ephy-navigation-action.c
diff options
context:
space:
mode:
authorChristian Persch <chpe@src.gnome.org>2003-09-02 07:20:17 +0800
committerChristian Persch <chpe@src.gnome.org>2003-09-02 07:20:17 +0800
commit73a95385f4034998cc78199dc8bb9ee22d90d6aa (patch)
tree499d78ab52e8937f672e3659105dda083a34c988 /src/ephy-navigation-action.c
parent3375c1878c4c0ebf4f5067d128024ea484208f62 (diff)
downloadgsoc2013-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 'src/ephy-navigation-action.c')
-rw-r--r--src/ephy-navigation-action.c25
1 files changed, 8 insertions, 17 deletions
diff --git a/src/ephy-navigation-action.c b/src/ephy-navigation-action.c
index 81a14ad67..769cd9e19 100644
--- a/src/ephy-navigation-action.c
+++ b/src/ephy-navigation-action.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 "ephy-navigation-action.h"
@@ -30,6 +32,8 @@ static void ephy_navigation_action_class_init (EphyNavigationActionClass *class)
static GObjectClass *parent_class = NULL;
+#define EPHY_NAVIGATION_ACTION_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), EPHY_TYPE_NAVIGATION_ACTION, EphyNavigationActionPrivate))
+
struct EphyNavigationActionPrivate
{
EphyWindow *window;
@@ -299,31 +303,17 @@ ephy_navigation_action_get_property (GObject *object,
}
static void
-ephy_navigation_action_finalize (GObject *object)
-{
- EphyNavigationAction *action = EPHY_NAVIGATION_ACTION (object);
-
- g_return_if_fail (action->priv != NULL);
-
- g_free (action->priv);
-
- G_OBJECT_CLASS (parent_class)->finalize (object);
-}
-
-static void
ephy_navigation_action_class_init (EphyNavigationActionClass *class)
{
- GtkActionClass *action_class;
GObjectClass *object_class = G_OBJECT_CLASS (class);
+ GtkActionClass *action_class = GTK_ACTION_CLASS (class);
- object_class->finalize = ephy_navigation_action_finalize;
object_class->set_property = ephy_navigation_action_set_property;
object_class->get_property = ephy_navigation_action_get_property;
parent_class = g_type_class_peek_parent (class);
- action_class = GTK_ACTION_CLASS (class);
- action_class->toolbar_item_type = EPHY_ARROW_TOOLBUTTON_TYPE;
+ action_class->toolbar_item_type = EPHY_TYPE_ARROW_TOOLBUTTON;
action_class->connect_proxy = connect_proxy;
g_object_class_install_property (object_class,
@@ -343,12 +333,13 @@ ephy_navigation_action_class_init (EphyNavigationActionClass *class)
G_TYPE_OBJECT,
G_PARAM_READWRITE));
+ g_type_class_add_private (object_class, sizeof(EphyNavigationActionPrivate));
}
static void
ephy_navigation_action_init (EphyNavigationAction *action)
{
- action->priv = g_new0 (EphyNavigationActionPrivate, 1);
+ action->priv = EPHY_NAVIGATION_ACTION_GET_PRIVATE (action);
}