diff options
author | Dodji Seketeli <dodji@src.gnome.org> | 2003-05-22 21:28:57 +0000 |
---|---|---|
committer | Dodji Seketeli <dodji@src.gnome.org> | 2003-05-22 21:28:57 +0000 |
commit | 27dc894605cf50a7118c669e5c9e965928dfc543 (patch) | |
tree | 7a7688b57d190e39b8946fd93d3e90c191356d0a /src/seleng | |
parent | 09d37b011a016c9a03880761fe22702ab0cc5b64 (diff) | |
download | libcroco-27dc894605cf50a7118c669e5c9e965928dfc543.tar.gz |
small api cleanup. Dodji.
small api cleanup.
Dodji.
Diffstat (limited to 'src/seleng')
-rw-r--r-- | src/seleng/cr-sel-eng.c | 2 | ||||
-rw-r--r-- | src/seleng/cr-style.c | 64 | ||||
-rw-r--r-- | src/seleng/cr-style.h | 7 |
3 files changed, 1 insertions, 72 deletions
diff --git a/src/seleng/cr-sel-eng.c b/src/seleng/cr-sel-eng.c index f452139..c961277 100644 --- a/src/seleng/cr-sel-eng.c +++ b/src/seleng/cr-sel-eng.c @@ -1170,7 +1170,7 @@ cr_sel_eng_get_matched_properties_from_cascade (CRSelEng *a_this, *the returned *a_style using cr_style_destroy(). *@return CR_OK upon successfull completion, an error code otherwise. */ -#if 1 +#if 0 enum CRStatus cr_sel_eng_get_matched_style (CRSelEng *a_this, CRCascade *a_cascade, diff --git a/src/seleng/cr-style.c b/src/seleng/cr-style.c index bffc7fc..5fdd5c6 100644 --- a/src/seleng/cr-style.c +++ b/src/seleng/cr-style.c @@ -1382,70 +1382,6 @@ cr_style_new (void) /** - *Instanciates a new #CRStyle from a ruleset statement. - *Actually walks through all declarations of the ruleset - *statement and for each of them, sets the corresponding field - *of the CRStyle structure. - *@param a_stmt the ruleset statement. - *@param a_parent_style the parent style: the style of the - *parent xml element. - *@param a_style out parameter. The newly built instance of #CRStyle. - *@return CR_OK upon successfull completion, an error code otherwise. - */ -enum CRStatus -cr_style_new_from_ruleset (CRStatement *a_stmt, - CRStyle *a_parent_style, - CRStyle **a_style) -{ - g_return_val_if_fail (a_stmt - && a_stmt->type == RULESET_STMT - && a_stmt->kind.ruleset, - CR_BAD_PARAM_ERROR) ; - - if (! *a_style) - { - *a_style = cr_style_new () ; - if (! *a_style) - { - cr_utils_trace_info ("Out of memory") ; - return CR_ERROR ; - } - } - - (*a_style)->parent_style = a_parent_style ; - return cr_style_set_style_from_ruleset (*a_style, a_stmt) ; -} - - -/** - *Sets an instance of #CRStyle from a ruleset type of css2 statement. - *@param a_this the current instance of #CRStyle. - *@param a_stmt the statement the css ruleset statement. - *@param a_parent_style the style of the parent node. - *@return CR_OK upon sucessfull statement, an error code otherwise. - */ -enum CRStatus -cr_style_set_style_from_ruleset (CRStyle *a_this, - CRStatement *a_stmt) -{ - CRDeclaration *decl = NULL ; - - g_return_val_if_fail (a_this - && a_stmt - && (a_stmt->type == RULESET_STMT), - CR_BAD_PARAM_ERROR) ; - - for (decl = a_stmt->kind.ruleset->decl_list ; - decl ; decl = decl->next) - { - cr_style_set_style_from_decl - (a_this, decl) ; - } - - return CR_OK ; -} - -/** *Walks through a css2 property declaration, and populated the *according field(s) in the #CRStyle structure. *If the properties or their value(s) are/is not known, diff --git a/src/seleng/cr-style.h b/src/seleng/cr-style.h index e1956e6..853bf12 100644 --- a/src/seleng/cr-style.h +++ b/src/seleng/cr-style.h @@ -245,16 +245,9 @@ cr_style_new (void) ; enum CRStatus -cr_style_new_from_ruleset (CRStatement *a_stmt, - CRStyle *a_parent_style, - CRStyle **a_style) ; -enum CRStatus cr_style_set_style_from_decl (CRStyle *a_this, CRDeclaration *a_decl) ; enum CRStatus -cr_style_set_style_from_ruleset (CRStyle *a_this, CRStatement *a_stmt) ; - -enum CRStatus cr_style_ref (CRStyle *a_this) ; gboolean |