typedef struct _GtkPizzaChild GtkPizzaChild;
typedef struct _GtkPizzaClass GtkPizzaClass;
-typedef struct _GtkPizzaAdjData GtkPizzaAdjData;
struct _GtkPizzaClass
{
gint y;
};
-struct _GtkPizzaAdjData
-{
- gint dx;
- gint dy;
-};
-
static void gtk_pizza_class_init (GtkPizzaClass *klass);
static void gtk_pizza_init (GtkPizza *pizza);
g_return_if_fail (GTK_IS_PIZZA (pizza));
pizza->m_xoffset = xoffset;
- // do something
+ /* do something */
}
void gtk_pizza_set_yoffset (GtkPizza *pizza, gint yoffset)
g_return_if_fail (GTK_IS_PIZZA (pizza));
pizza->m_xoffset = yoffset;
- // do something
+ /* do something */
}
gint gtk_pizza_get_rtl_offset (GtkPizza *pizza)
gtk_widget_set_parent (widget, GTK_WIDGET (pizza));
gtk_widget_set_size_request( widget, width, height );
- if (GTK_WIDGET_REALIZED (pizza))
- gtk_pizza_allocate_child (pizza, child_info);
}
void
if (pizza->bin_window)
gdk_window_scroll( pizza->bin_window, -dx, -dy );
-
- tmp_list = pizza->children;
- while (tmp_list)
+
+ for (tmp_list = pizza->children; tmp_list; tmp_list = tmp_list->next)
{
GtkPizzaChild *child = tmp_list->data;
- tmp_list = tmp_list->next;
-
- GtkAllocation alloc = child->widget->allocation;
- alloc.x -= dx;
- alloc.y -= dy;
- gtk_widget_size_allocate( child->widget, &alloc );
+ gtk_widget_queue_resize(child->widget);
}
}