From 95fd8bf585ec69e1811bec0a4d5296704d899e63 Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Sun, 15 Feb 2009 09:24:49 +0000 Subject: Pay attention to the disabled flag on top-level stylesheets svn path=/trunk/libcss/; revision=6520 --- src/select/select.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/select/select.c b/src/select/select.c index 0c31ae4..9efc912 100644 --- a/src/select/select.c +++ b/src/select/select.c @@ -442,9 +442,11 @@ css_error css_select_style(css_select_ctx *ctx, void *node, state.pw = pw; /* Iterate through the top-level stylesheets, selecting styles - * from those which apply to our current media requirements */ + * from those which apply to our current media requirements and + * are not disabled */ for (i = 0; i < ctx->n_sheets; i++) { - if ((ctx->sheets[i]->media & media) != 0) { + if ((ctx->sheets[i]->media & media) != 0 && + ctx->sheets[i]->disabled == false) { error = select_from_sheet(ctx, ctx->sheets[i], &state); if (error != CSS_OK) goto cleanup; -- cgit v1.2.3