summaryrefslogtreecommitdiff
path: root/render/html_internal.h
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2016-09-24 12:44:28 +0100
committerMichael Drake <tlsa@netsurf-browser.org>2016-09-24 12:44:28 +0100
commit7b78ef336122f28c2d2b4cce253683941a31b797 (patch)
treeaf47a69a884b612be0ce8c081b5f674082810b98 /render/html_internal.h
parent1ef1edc9e0bc001f3324bc7fa616c4bd0cc79466 (diff)
downloadnetsurf-7b78ef336122f28c2d2b4cce253683941a31b797.tar.gz
netsurf-7b78ef336122f28c2d2b4cce253683941a31b797.tar.bz2
Style: Fix ignoring of STYLE elements with non-screen media.
We were handling the STYLE tag getting added in the dom_default_action_DOMSubtreeModified_cb callback, however, the media attribute dadn't been added by that point. We now check it in the dom_default_action_DOMNodeInserted_cb callback, at which time the media attribute is available for checking. Note, we should probably store the media type in the html_stylesheet structure, but for now we just have an `unused` boolean. Also, it may be possible to optimise to avoid parsing non- screen media STYLE element data if we could detect the media earlier.
Diffstat (limited to 'render/html_internal.h')
-rw-r--r--render/html_internal.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/render/html_internal.h b/render/html_internal.h
index f0e98158f..fd65707ce 100644
--- a/render/html_internal.h
+++ b/render/html_internal.h
@@ -321,6 +321,7 @@ nserror html_css_quirks_stylesheets(html_content *c);
nserror html_css_free_stylesheets(html_content *html);
bool html_css_process_link(html_content *htmlc, dom_node *node);
+bool html_css_process_style(html_content *htmlc, dom_node *node);
bool html_css_update_style(html_content *c, dom_node *style);
nserror html_css_new_selection_context(html_content *c,