| OLD | NEW |
| 1 /* | 1 /* |
| 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) | 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) |
| 3 * Copyright (C) 2004, 2006, 2007, 2012 Apple Inc. All rights reserved. | 3 * Copyright (C) 2004, 2006, 2007, 2012 Apple Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 Node& ownerNode, | 103 Node& ownerNode, |
| 104 const TextPosition& startPosition) { | 104 const TextPosition& startPosition) { |
| 105 DCHECK(sheet); | 105 DCHECK(sheet); |
| 106 return new CSSStyleSheet(sheet, ownerNode, true, startPosition); | 106 return new CSSStyleSheet(sheet, ownerNode, true, startPosition); |
| 107 } | 107 } |
| 108 | 108 |
| 109 CSSStyleSheet* CSSStyleSheet::createInline(Node& ownerNode, | 109 CSSStyleSheet* CSSStyleSheet::createInline(Node& ownerNode, |
| 110 const KURL& baseURL, | 110 const KURL& baseURL, |
| 111 const TextPosition& startPosition, | 111 const TextPosition& startPosition, |
| 112 const String& encoding) { | 112 const String& encoding) { |
| 113 CSSParserContext* parserContext = | 113 CSSParserContext* parserContext = CSSParserContext::create( |
| 114 CSSParserContext::create(ownerNode.document(), baseURL, encoding); | 114 ownerNode.document(), ownerNode.document().baseURL(), |
| 115 ownerNode.document().getReferrerPolicy(), encoding); |
| 115 StyleSheetContents* sheet = | 116 StyleSheetContents* sheet = |
| 116 StyleSheetContents::create(baseURL.getString(), parserContext); | 117 StyleSheetContents::create(baseURL.getString(), parserContext); |
| 117 return new CSSStyleSheet(sheet, ownerNode, true, startPosition); | 118 return new CSSStyleSheet(sheet, ownerNode, true, startPosition); |
| 118 } | 119 } |
| 119 | 120 |
| 120 CSSStyleSheet::CSSStyleSheet(StyleSheetContents* contents, | 121 CSSStyleSheet::CSSStyleSheet(StyleSheetContents* contents, |
| 121 CSSImportRule* ownerRule) | 122 CSSImportRule* ownerRule) |
| 122 : m_contents(contents), | 123 : m_contents(contents), |
| 123 m_ownerRule(ownerRule), | 124 m_ownerRule(ownerRule), |
| 124 m_startPosition(TextPosition::minimumPosition()) { | 125 m_startPosition(TextPosition::minimumPosition()) { |
| (...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 449 visitor->trace(m_deviceDependentMediaQueryResults); | 450 visitor->trace(m_deviceDependentMediaQueryResults); |
| 450 visitor->trace(m_ownerNode); | 451 visitor->trace(m_ownerNode); |
| 451 visitor->trace(m_ownerRule); | 452 visitor->trace(m_ownerRule); |
| 452 visitor->trace(m_mediaCSSOMWrapper); | 453 visitor->trace(m_mediaCSSOMWrapper); |
| 453 visitor->trace(m_childRuleCSSOMWrappers); | 454 visitor->trace(m_childRuleCSSOMWrappers); |
| 454 visitor->trace(m_ruleListCSSOMWrapper); | 455 visitor->trace(m_ruleListCSSOMWrapper); |
| 455 StyleSheet::trace(visitor); | 456 StyleSheet::trace(visitor); |
| 456 } | 457 } |
| 457 | 458 |
| 458 } // namespace blink | 459 } // namespace blink |
| OLD | NEW |