summaryrefslogtreecommitdiff
path: root/gtk/gtkcssimageradial.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2016-11-07 15:40:21 -0500
committerMatthias Clasen <mclasen@redhat.com>2016-11-07 15:40:21 -0500
commit2a5a94b2606ffae08fce634e61c533830f54c3ec (patch)
tree1c286af1a3083ce002a6d8d4b3cc1988944944bf /gtk/gtkcssimageradial.c
parentfa7d77d40732281a8838a314bcc39a0007182320 (diff)
downloadgtk+-2a5a94b2606ffae08fce634e61c533830f54c3ec.tar.gz
css: Improve spec compliance of the radial gradient parser
The spec says: "If <shape> is omitted, the ending shape defaults to a circle if the <size> is a single <length>, and to an ellipse otherwise." Make it so.
Diffstat (limited to 'gtk/gtkcssimageradial.c')
-rw-r--r--gtk/gtkcssimageradial.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gtk/gtkcssimageradial.c b/gtk/gtkcssimageradial.c
index 1d4b99bc18..e22d9b805b 100644
--- a/gtk/gtkcssimageradial.c
+++ b/gtk/gtkcssimageradial.c
@@ -323,10 +323,10 @@ gtk_css_image_radial_parse (GtkCssImage *image,
if (!has_shape)
{
- if (radial->sizes[0] && radial->sizes[1])
- radial->circle = FALSE;
- else
+ if (radial->sizes[0] && !radial->sizes[1])
radial->circle = TRUE;
+ else
+ radial->circle = FALSE;
}
if (has_shape && radial->circle)