From 570510b0762d9bb02f9dc64497c8802bc2a1649d Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Mon, 23 Mar 2009 01:02:59 +0000 Subject: Completely change the approach used for presentational hints. This one stands a chance of working sanely. While this compiles, please don't expect it to link. svn path=/trunk/libcss/; revision=6820 --- test/select-auto.c | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) (limited to 'test/select-auto.c') diff --git a/test/select-auto.c b/test/select-auto.c index a0e63da..86c9f89 100644 --- a/test/select-auto.c +++ b/test/select-auto.c @@ -112,6 +112,8 @@ static css_error node_is_active(void *pw, void *node, bool *match); static css_error node_is_focus(void *pw, void *node, bool *match); static css_error node_is_lang(void *pw, void *node, lwc_string *lang, bool *match); +static css_error node_presentational_hint(void *pw, void *node, + uint32_t property, css_hint *hint); static css_select_handler select_handler = { node_name, @@ -132,7 +134,8 @@ static css_select_handler select_handler = { node_is_hover, node_is_active, node_is_focus, - node_is_lang + node_is_lang, + node_presentational_hint }; static void *myrealloc(void *data, size_t len, void *pw) @@ -151,6 +154,9 @@ int main(int argc, char **argv) return 1; } + printf("css_hint: %lu\n", sizeof(css_hint)); + printf("computed: %lu\n", sizeof(css_computed_style)); + assert(css_initialise(argv[1], myrealloc, NULL) == CSS_OK); memset(&ctx, 0, sizeof(ctx)); @@ -631,8 +637,7 @@ void run_test(line_ctx *ctx, const char *exp, size_t explen) testnum++; assert(css_select_style(select, ctx->target, ctx->pseudo_element, - ctx->media, NULL, computed, &select_handler, ctx) == - CSS_OK); + ctx->media, computed, &select_handler, ctx) == CSS_OK); dump_computed_style(computed, buf, &buflen); @@ -1052,3 +1057,14 @@ css_error node_is_lang(void *pw, void *n, return CSS_OK; } +css_error node_presentational_hint(void *pw, void *node, + uint32_t property, css_hint *hint) +{ + UNUSED(pw); + UNUSED(node); + UNUSED(property); + UNUSED(hint); + + return CSS_OK; +} + -- cgit v1.2.3