summaryrefslogtreecommitdiff
path: root/src/select/select.c
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2009-02-15 09:24:49 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2009-02-15 09:24:49 +0000
commit95fd8bf585ec69e1811bec0a4d5296704d899e63 (patch)
tree541511cb2a1808afbb86654544200f0cef7f4d44 /src/select/select.c
parent90e05332d329663b9616bae2792b7cb36d03e13f (diff)
downloadlibcss-95fd8bf585ec69e1811bec0a4d5296704d899e63.tar.gz
libcss-95fd8bf585ec69e1811bec0a4d5296704d899e63.tar.bz2
Pay attention to the disabled flag on top-level stylesheets
svn path=/trunk/libcss/; revision=6520
Diffstat (limited to 'src/select/select.c')
-rw-r--r--src/select/select.c6
1 files changed, 4 insertions, 2 deletions
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;