summaryrefslogtreecommitdiff
path: root/src/css.hh
diff options
context:
space:
mode:
authorJohannes Hofmann <Johannes.Hofmann@gmx.de>2011-08-02 23:25:49 +0200
committerJohannes Hofmann <Johannes.Hofmann@gmx.de>2011-08-02 23:25:49 +0200
commit23185b807ebdbed2b792dcb4abe729d2e7d17ba7 (patch)
treed5d0b47a5651328864407141ea51303ed5a2bf41 /src/css.hh
parent36a5a683ff482bf45ade423d6f1dafa3c9627c81 (diff)
don't reuse user- and useragent-stylesheet
The notMatchingBefore variable in CssSelector is modified as a page is styled. Thererfore we can't share a single copy of the user- and useragent-stylesheets between CssContexts. Testcase: <html> <body> <a href=whatever.html> <img alt=test src=whatever.jpg> </a> <div> <img src=something.jpg> </div> </body> </html> On reload the first image looses it's border. Tests with gettimeofday showed times below 1ms to create user- and useragent-styles on a Pentium-M 1.8 GHz laptop. reported-by: corvid <corvid@lavabit.com>
Diffstat (limited to 'src/css.hh')
-rw-r--r--src/css.hh3
1 files changed, 0 insertions, 3 deletions
diff --git a/src/css.hh b/src/css.hh
index 61c1d12f..20935dfd 100644
--- a/src/css.hh
+++ b/src/css.hh
@@ -458,9 +458,6 @@ class CssStyleSheet {
*/
class CssContext {
private:
- static CssStyleSheet *userAgentStyle;
- static CssStyleSheet *userStyle;
- static CssStyleSheet *userImportantStyle;
CssStyleSheet *sheet[CSS_PRIMARY_USER_IMPORTANT + 1];
int pos;