g_return_if_fail (GTK_IS_CONTAINER (container));
g_return_if_fail (resize_mode <= GTK_RESIZE_IMMEDIATE);
- if (GTK_WIDGET_TOPLEVEL (container) &&
+ if (gtk_widget_is_toplevel (GTK_WIDGET (container)) &&
resize_mode == GTK_RESIZE_PARENT)
{
resize_mode = GTK_RESIZE_QUEUE;
if (resize_container)
{
if (GTK_WIDGET_VISIBLE (resize_container) &&
- (GTK_WIDGET_TOPLEVEL (resize_container) || GTK_WIDGET_REALIZED (resize_container)))
+ (gtk_widget_is_toplevel (GTK_WIDGET (resize_container)) || GTK_WIDGET_REALIZED (resize_container)))
{
switch (resize_container->resize_mode)
{
/**
* gtk_container_set_focus_child:
* @container: a #GtkContainer
- * @child: a #GtkWidget, or %NULL
+ * @child: (allow-none): a #GtkWidget, or %NULL
*
* Sets, or unsets if @child is %NULL, the focused child of @container.
*
* @container: a #GtkContainer
*
* Returns the container's non-internal children. See
- * gtk_container_forall() for details on what constitutes an "internal" child.
+ * gtk_container_forall() for details on what constitutes an "internal" child.
*
- * Return value: a newly-allocated list of the container's non-internal children.
+ * Return value: (element-type GtkWidget) (transfer container): a newly-allocated list of the container's non-internal children.
**/
GList*
gtk_container_get_children (GtkContainer *container)
_gtk_container_child_composite_name (GtkContainer *container,
GtkWidget *child)
{
+ gboolean composite_child;
+
g_return_val_if_fail (GTK_IS_CONTAINER (container), NULL);
g_return_val_if_fail (GTK_IS_WIDGET (child), NULL);
g_return_val_if_fail (child->parent == GTK_WIDGET (container), NULL);
- if (GTK_WIDGET_COMPOSITE_CHILD (child))
+ g_object_get (child, "composite-child", &composite_child, NULL);
+ if (composite_child)
{
static GQuark quark_composite_name = 0;
gchar *name;
/**
* gtk_container_get_focus_chain:
* @container: a #GtkContainer
- * @focusable_widgets: location to store the focus chain of the
+ * @focusable_widgets: (element-type GtkWidget) (out) (transfer container): location
+ * to store the focus chain of the
* container, or %NULL. You should free this list
* using g_list_free() when you are done with it, however
* no additional reference count is added to the
* Retrieves the vertical focus adjustment for the container. See
* gtk_container_set_focus_vadjustment().
*
- * Return value: the vertical focus adjustment, or %NULL if
+ * Return value: (transfer none): the vertical focus adjustment, or %NULL if
* none has been set.
**/
GtkAdjustment *
* Retrieves the horizontal focus adjustment for the container. See
* gtk_container_set_focus_hadjustment ().
*
- * Return value: the horizontal focus adjustment, or %NULL if
+ * Return value: (transfer none): the horizontal focus adjustment, or %NULL if
* none has been set.
**/
GtkAdjustment *