From 87d7c3d3dee8d22af977e346ba1c139131152077 Mon Sep 17 00:00:00 2001 From: Daniel Silverstone Date: Sun, 28 Mar 2010 00:13:41 +0000 Subject: Make libcss suitable for the new libwapcaplet behaviour. svn path=/trunk/libcss/; revision=10168 --- src/parse/properties/margin.c | 72 +++++++++++++++++++++---------------------- 1 file changed, 36 insertions(+), 36 deletions(-) (limited to 'src/parse/properties/margin.c') diff --git a/src/parse/properties/margin.c b/src/parse/properties/margin.c index 456e6ee..b3b390c 100644 --- a/src/parse/properties/margin.c +++ b/src/parse/properties/margin.c @@ -1,7 +1,7 @@ /* * This file is part of LibCSS. * Licensed under the MIT License, - * http://www.opensource.org/licenses/mit-license.php + * http://www.opensource.org/licenses/mit-license.php * Copyright 2009 John-Mark Bell */ @@ -20,16 +20,16 @@ static css_error parse_margin_side(css_language *c, /** * Parse margin shorthand * - * \param c Parsing context + * \param c Parsing context * \param vector Vector of tokens to process - * \param ctx Pointer to vector iteration context + * \param ctx Pointer to vector iteration context * \param result Pointer to location to receive resulting style * \return CSS_OK on success, - * CSS_NOMEM on memory exhaustion, - * CSS_INVALID if the input is not valid + * CSS_NOMEM on memory exhaustion, + * CSS_INVALID if the input is not valid * * Post condition: \a *ctx is updated with the next token to process - * If the input is invalid, then \a *ctx remains unchanged. + * If the input is invalid, then \a *ctx remains unchanged. */ css_error parse_margin(css_language *c, const parserutils_vector *vector, int *ctx, @@ -249,15 +249,15 @@ css_error parse_margin(css_language *c, /* Clean up after ourselves */ cleanup: if (top) - css_stylesheet_style_destroy(c->sheet, top); + css_stylesheet_style_destroy(c->sheet, top, error == CSS_OK); if (right) - css_stylesheet_style_destroy(c->sheet, right); + css_stylesheet_style_destroy(c->sheet, right, error == CSS_OK); if (bottom) - css_stylesheet_style_destroy(c->sheet, bottom); + css_stylesheet_style_destroy(c->sheet, bottom, error == CSS_OK); if (left) - css_stylesheet_style_destroy(c->sheet, left); + css_stylesheet_style_destroy(c->sheet, left, error == CSS_OK); if (ret) - css_stylesheet_style_destroy(c->sheet, ret); + css_stylesheet_style_destroy(c->sheet, ret, error == CSS_OK); if (error != CSS_OK) *ctx = orig_ctx; @@ -268,16 +268,16 @@ cleanup: /** * Parse margin-bottom * - * \param c Parsing context + * \param c Parsing context * \param vector Vector of tokens to process - * \param ctx Pointer to vector iteration context + * \param ctx Pointer to vector iteration context * \param result Pointer to location to receive resulting style * \return CSS_OK on success, - * CSS_NOMEM on memory exhaustion, - * CSS_INVALID if the input is not valid + * CSS_NOMEM on memory exhaustion, + * CSS_INVALID if the input is not valid * * Post condition: \a *ctx is updated with the next token to process - * If the input is invalid, then \a *ctx remains unchanged. + * If the input is invalid, then \a *ctx remains unchanged. */ css_error parse_margin_bottom(css_language *c, const parserutils_vector *vector, int *ctx, @@ -290,16 +290,16 @@ css_error parse_margin_bottom(css_language *c, /** * Parse margin-left * - * \param c Parsing context + * \param c Parsing context * \param vector Vector of tokens to process - * \param ctx Pointer to vector iteration context + * \param ctx Pointer to vector iteration context * \param result Pointer to location to receive resulting style * \return CSS_OK on success, - * CSS_NOMEM on memory exhaustion, - * CSS_INVALID if the input is not valid + * CSS_NOMEM on memory exhaustion, + * CSS_INVALID if the input is not valid * * Post condition: \a *ctx is updated with the next token to process - * If the input is invalid, then \a *ctx remains unchanged. + * If the input is invalid, then \a *ctx remains unchanged. */ css_error parse_margin_left(css_language *c, const parserutils_vector *vector, int *ctx, @@ -311,16 +311,16 @@ css_error parse_margin_left(css_language *c, /** * Parse margin-right * - * \param c Parsing context + * \param c Parsing context * \param vector Vector of tokens to process - * \param ctx Pointer to vector iteration context + * \param ctx Pointer to vector iteration context * \param result Pointer to location to receive resulting style * \return CSS_OK on success, - * CSS_NOMEM on memory exhaustion, - * CSS_INVALID if the input is not valid + * CSS_NOMEM on memory exhaustion, + * CSS_INVALID if the input is not valid * * Post condition: \a *ctx is updated with the next token to process - * If the input is invalid, then \a *ctx remains unchanged. + * If the input is invalid, then \a *ctx remains unchanged. */ css_error parse_margin_right(css_language *c, const parserutils_vector *vector, int *ctx, @@ -332,16 +332,16 @@ css_error parse_margin_right(css_language *c, /** * Parse margin-top * - * \param c Parsing context + * \param c Parsing context * \param vector Vector of tokens to process - * \param ctx Pointer to vector iteration context + * \param ctx Pointer to vector iteration context * \param result Pointer to location to receive resulting style * \return CSS_OK on success, - * CSS_NOMEM on memory exhaustion, - * CSS_INVALID if the input is not valid + * CSS_NOMEM on memory exhaustion, + * CSS_INVALID if the input is not valid * * Post condition: \a *ctx is updated with the next token to process - * If the input is invalid, then \a *ctx remains unchanged. + * If the input is invalid, then \a *ctx remains unchanged. */ css_error parse_margin_top(css_language *c, const parserutils_vector *vector, int *ctx, @@ -353,16 +353,16 @@ css_error parse_margin_top(css_language *c, /** * Parse margin-{top,right,bottom,left} * - * \param c Parsing context + * \param c Parsing context * \param vector Vector of tokens to process - * \param ctx Pointer to vector iteration context + * \param ctx Pointer to vector iteration context * \param result Pointer to location to receive resulting style * \return CSS_OK on success, - * CSS_NOMEM on memory exhaustion, - * CSS_INVALID if the input is not valid + * CSS_NOMEM on memory exhaustion, + * CSS_INVALID if the input is not valid * * Post condition: \a *ctx is updated with the next token to process - * If the input is invalid, then \a *ctx remains unchanged. + * If the input is invalid, then \a *ctx remains unchanged. */ css_error parse_margin_side(css_language *c, const parserutils_vector *vector, int *ctx, -- cgit v1.2.3