summaryrefslogtreecommitdiff
path: root/src/select/select.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/select/select.c')
-rw-r--r--src/select/select.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/select/select.c b/src/select/select.c
index 8eb04dc..04dff1f 100644
--- a/src/select/select.c
+++ b/src/select/select.c
@@ -53,6 +53,8 @@ typedef struct css_select_state {
css_select_handler *handler; /* Handler functions */
void *pw; /* Client data for handlers */
+ const css_stylesheet *sheet; /* Current sheet being processed */
+
css_origin current_origin; /* Origin of current sheet */
uint32_t current_specificity; /* Specificity of current rule */
@@ -477,6 +479,7 @@ css_error select_from_sheet(css_select_ctx *ctx, const css_stylesheet *sheet,
css_error error;
/* Process this sheet */
+ state->sheet = s;
state->current_origin = s->origin;
error = match_selectors_in_sheet(ctx, s, state);