path: root/src/select/hash.h
diff options
authorMichael Drake <>2019-05-04 14:10:41 +0100
committerMichael Drake <>2019-05-04 14:10:41 +0100
commit5d1a706bfc5d25ea0fc2060772e44222ea711df5 (patch)
tree548af2617882f5be239ea188d1c964245cfc06b3 /src/select/hash.h
parentd6126aa77eb442f446d28b6dfb15a884f209a341 (diff)
Media queries: Update selection API to support media queries.
The API changes are: 1. When building a selection context, stylesheets added with `css_select_ctx_{append|insert}_sheet()` now have to have media strings associcated with them. Previously they took a simple bitfield for CSS media type. 2. When selecting for an element, the client needs to specify the current media requirements. Previously it only had to provide the bitfield for CSS media type. 3. Same for the css_select_font_faces API. The selection handling has been updated to handle the new API, however it is currently only looking at the media type when performing selection. Signed-off-by: Michael Drake <>
Diffstat (limited to 'src/select/hash.h')
1 files changed, 1 insertions, 1 deletions
diff --git a/src/select/hash.h b/src/select/hash.h
index 71f610f..aecf15a 100644
--- a/src/select/hash.h
+++ b/src/select/hash.h
@@ -25,7 +25,7 @@ struct css_hash_selection_requirments {
lwc_string *class; /* Name of class, or NULL */
lwc_string *id; /* Name of id, or NULL */
lwc_string *uni; /* Universal element string "*" */
- uint64_t media; /* Media type(s) we're selecting for */
+ const css_media *media; /* Media spec we're selecting for */
const css_bloom *node_bloom; /* Node's bloom filter */