aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/misc/e-paned.c
diff options
context:
space:
mode:
Diffstat (limited to 'widgets/misc/e-paned.c')
-rw-r--r--widgets/misc/e-paned.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/widgets/misc/e-paned.c b/widgets/misc/e-paned.c
index 83f9614e74..2b4701b9ff 100644
--- a/widgets/misc/e-paned.c
+++ b/widgets/misc/e-paned.c
@@ -93,7 +93,7 @@ paned_notify_orientation_cb (EPaned *paned)
static void
paned_notify_position_cb (EPaned *paned)
{
- GtkAllocation *allocation;
+ GtkAllocation allocation;
GtkOrientable *orientable;
GtkOrientation orientation;
gdouble proportion;
@@ -106,20 +106,20 @@ paned_notify_position_cb (EPaned *paned)
orientable = GTK_ORIENTABLE (paned);
orientation = gtk_orientable_get_orientation (orientable);
- allocation = &GTK_WIDGET (paned)->allocation;
+ gtk_widget_get_allocation (GTK_WIDGET (paned), &allocation);
position = gtk_paned_get_position (GTK_PANED (paned));
g_object_freeze_notify (G_OBJECT (paned));
if (orientation == GTK_ORIENTATION_HORIZONTAL) {
- position = MAX (0, allocation->width - position);
- proportion = (gdouble) position / allocation->width;
+ position = MAX (0, allocation.width - position);
+ proportion = (gdouble) position / allocation.width;
paned->priv->hposition = position;
g_object_notify (G_OBJECT (paned), "hposition");
} else {
- position = MAX (0, allocation->height - position);
- proportion = (gdouble) position / allocation->height;
+ position = MAX (0, allocation.height - position);
+ proportion = (gdouble) position / allocation.height;
paned->priv->vposition = position;
g_object_notify (G_OBJECT (paned), "vposition");