aboutsummaryrefslogtreecommitdiffstats
path: root/lib/widgets/ephy-arrow-toolbutton.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 /lib/widgets/ephy-arrow-toolbutton.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 'lib/widgets/ephy-arrow-toolbutton.c')
-rw-r--r--lib/widgets/ephy-arrow-toolbutton.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/widgets/ephy-arrow-toolbutton.c b/lib/widgets/ephy-arrow-toolbutton.c
index e40237f5f..147c7d80b 100644
--- a/lib/widgets/ephy-arrow-toolbutton.c
+++ b/lib/widgets/ephy-arrow-toolbutton.c
@@ -16,7 +16,6 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
* $Id$
- *
*/
#include "ephy-arrow-toolbutton.h"
@@ -30,6 +29,8 @@
#include <gtk/gtkmenu.h>
#include <gtk/gtkmain.h>
+#define EPHY_ARROW_TOOLBUTTON_GET_PRIVATE(object)(G_TYPE_INSTANCE_GET_PRIVATE ((object), EPHY_TYPE_ARROW_TOOLBUTTON, EphyArrowToolButtonPrivate))
+
struct EphyArrowToolButtonPrivate
{
GtkWidget *arrow_widget;
@@ -88,7 +89,7 @@ ephy_arrow_toolbutton_set_tooltip (GtkToolItem *tool_item,
{
EphyArrowToolButton *button = EPHY_ARROW_TOOLBUTTON (tool_item);
- g_return_val_if_fail (IS_EPHY_ARROW_TOOLBUTTON (button), FALSE);
+ g_return_val_if_fail (EPHY_IS_ARROW_TOOLBUTTON (button), FALSE);
gtk_tooltips_set_tip (tooltips, button->priv->button, tip_text, tip_private);
@@ -115,6 +116,8 @@ ephy_arrow_toolbutton_class_init (EphyArrowToolButtonClass *klass)
NULL, NULL,
ephy_marshal_VOID__VOID,
G_TYPE_NONE, 0);
+
+ g_type_class_add_private (object_class, sizeof (EphyArrowToolButtonPrivate));
}
static void
@@ -202,7 +205,7 @@ ephy_arrow_toolbutton_init (EphyArrowToolButton *arrowtb)
GtkWidget *arrow_button;
GtkWidget *real_button;
- arrowtb->priv = g_new (EphyArrowToolButtonPrivate, 1);
+ arrowtb->priv = EPHY_ARROW_TOOLBUTTON_GET_PRIVATE (arrowtb);
gtk_tool_item_set_homogeneous (GTK_TOOL_ITEM (arrowtb), FALSE);
@@ -256,8 +259,6 @@ ephy_arrow_toolbutton_finalize (GObject *object)
gtk_widget_destroy (GTK_WIDGET (arrow_toolbutton->priv->menu));
- g_free (arrow_toolbutton->priv);
-
G_OBJECT_CLASS (parent_class)->finalize (object);
}