st: Remove deprecated Bin properties

Those were deprecated last cycle in favor of ClutterActor's own
expand/align properties, and don't have any effect anymore.

Time to remove them for good.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1273
This commit is contained in:
Florian Müllner 2020-05-21 05:21:47 +02:00
parent faaed642a7
commit 9c3c9a155e
2 changed files with 0 additions and 123 deletions

View File

@ -42,9 +42,6 @@ typedef struct _StBinPrivate StBinPrivate;
struct _StBinPrivate
{
ClutterActor *child;
guint x_fill : 1;
guint y_fill : 1;
};
enum
@ -52,8 +49,6 @@ enum
PROP_0,
PROP_CHILD,
PROP_X_FILL,
PROP_Y_FILL,
N_PROPS
};
@ -258,7 +253,6 @@ st_bin_set_property (GObject *gobject,
GParamSpec *pspec)
{
StBin *bin = ST_BIN (gobject);
StBinPrivate *priv = st_bin_get_instance_private (bin);
switch (prop_id)
{
@ -266,18 +260,6 @@ st_bin_set_property (GObject *gobject,
st_bin_set_child (bin, g_value_get_object (value));
break;
case PROP_X_FILL:
st_bin_set_fill (bin,
g_value_get_boolean (value),
priv->y_fill);
break;
case PROP_Y_FILL:
st_bin_set_fill (bin,
priv->x_fill,
g_value_get_boolean (value));
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (gobject, prop_id, pspec);
}
@ -297,14 +279,6 @@ st_bin_get_property (GObject *gobject,
g_value_set_object (value, priv->child);
break;
case PROP_X_FILL:
g_value_set_boolean (value, priv->x_fill);
break;
case PROP_Y_FILL:
g_value_set_boolean (value, priv->y_fill);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (gobject, prop_id, pspec);
}
@ -340,32 +314,6 @@ st_bin_class_init (StBinClass *klass)
CLUTTER_TYPE_ACTOR,
ST_PARAM_READWRITE);
/**
* StBin:x-fill:
*
* Whether the child should fill the horizontal allocation
*/
props[PROP_X_FILL] =
g_param_spec_boolean ("x-fill",
"X Fill",
"Whether the child should fill the "
"horizontal allocation",
FALSE,
ST_PARAM_READWRITE | G_PARAM_DEPRECATED);
/**
* StBin:y-fill:
*
* Whether the child should fill the vertical allocation
*/
props[PROP_Y_FILL] =
g_param_spec_boolean ("y-fill",
"Y Fill",
"Whether the child should fill the "
"vertical allocation",
FALSE,
ST_PARAM_READWRITE | G_PARAM_DEPRECATED);
g_object_class_install_properties (gobject_class, N_PROPS, props);
}
@ -441,68 +389,3 @@ st_bin_get_child (StBin *bin)
return ((StBinPrivate *)st_bin_get_instance_private (bin))->child;
}
/**
* st_bin_set_fill:
* @bin: a #StBin
* @x_fill: %TRUE if the child should fill horizontally the @bin
* @y_fill: %TRUE if the child should fill vertically the @bin
*
* Sets whether the child of @bin should fill out the horizontal
* and/or vertical allocation of the parent
*/
void
st_bin_set_fill (StBin *bin,
gboolean x_fill,
gboolean y_fill)
{
StBinPrivate *priv;
g_return_if_fail (ST_IS_BIN (bin));
priv = st_bin_get_instance_private (bin);
g_object_freeze_notify (G_OBJECT (bin));
if (priv->x_fill != x_fill)
{
priv->x_fill = x_fill;
g_object_notify_by_pspec (G_OBJECT (bin), props[PROP_X_FILL]);
}
if (priv->y_fill != y_fill)
{
priv->y_fill = y_fill;
g_object_notify_by_pspec (G_OBJECT (bin), props[PROP_Y_FILL]);
}
g_object_thaw_notify (G_OBJECT (bin));
}
/**
* st_bin_get_fill:
* @bin: a #StBin
* @x_fill: (out): return location for the horizontal fill, or %NULL
* @y_fill: (out): return location for the vertical fill, or %NULL
*
* Retrieves the horizontal and vertical fill settings
*/
void
st_bin_get_fill (StBin *bin,
gboolean *x_fill,
gboolean *y_fill)
{
StBinPrivate *priv;
g_return_if_fail (ST_IS_BIN (bin));
priv = st_bin_get_instance_private (bin);
if (x_fill)
*x_fill = priv->x_fill;
if (y_fill)
*y_fill = priv->y_fill;
}

View File

@ -47,12 +47,6 @@ StWidget * st_bin_new (void);
void st_bin_set_child (StBin *bin,
ClutterActor *child);
ClutterActor *st_bin_get_child (StBin *bin);
void st_bin_set_fill (StBin *bin,
gboolean x_fill,
gboolean y_fill);
void st_bin_get_fill (StBin *bin,
gboolean *x_fill,
gboolean *y_fill);
G_END_DECLS