OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2010 Google, Inc. All Rights Reserved. | 2 * Copyright (C) 2010 Google, Inc. All Rights Reserved. |
3 * Copyright (C) 2011 Apple Inc. All rights reserved. | 3 * Copyright (C) 2011 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
189 void setInsertionMode(InsertionMode mode) { m_insertionMode = mode; } | 189 void setInsertionMode(InsertionMode mode) { m_insertionMode = mode; } |
190 | 190 |
191 void resetInsertionModeAppropriately(); | 191 void resetInsertionModeAppropriately(); |
192 | 192 |
193 void processTemplateStartTag(AtomicHTMLToken*); | 193 void processTemplateStartTag(AtomicHTMLToken*); |
194 bool processTemplateEndTag(AtomicHTMLToken*); | 194 bool processTemplateEndTag(AtomicHTMLToken*); |
195 bool processEndOfFileForInTemplateContents(AtomicHTMLToken*); | 195 bool processEndOfFileForInTemplateContents(AtomicHTMLToken*); |
196 | 196 |
197 class FragmentParsingContext { | 197 class FragmentParsingContext { |
198 WTF_MAKE_NONCOPYABLE(FragmentParsingContext); | 198 WTF_MAKE_NONCOPYABLE(FragmentParsingContext); |
199 DISALLOW_ALLOCATION(); | |
199 public: | 200 public: |
200 FragmentParsingContext(); | 201 FragmentParsingContext(); |
201 FragmentParsingContext(DocumentFragment*, Element* contextElement); | 202 FragmentParsingContext(DocumentFragment*, Element* contextElement); |
202 ~FragmentParsingContext(); | 203 ~FragmentParsingContext(); |
203 | 204 |
204 DocumentFragment* fragment() const { return m_fragment; } | 205 DocumentFragment* fragment() const { return m_fragment; } |
205 Element* contextElement() const { ASSERT(m_fragment); return m_contextEl ementStackItem->element(); } | 206 Element* contextElement() const { ASSERT(m_fragment); return m_contextEl ementStackItem->element(); } |
206 HTMLStackItem* contextElementStackItem() const { ASSERT(m_fragment); ret urn m_contextElementStackItem.get(); } | 207 HTMLStackItem* contextElementStackItem() const { ASSERT(m_fragment); ret urn m_contextElementStackItem.get(); } |
207 | 208 |
209 void trace(Visitor* visitor) { visitor->trace(m_contextElementStackItem) ; } | |
210 | |
208 private: | 211 private: |
209 DocumentFragment* m_fragment; | 212 DocumentFragment* m_fragment; |
haraken
2014/05/27 10:48:22
You can make this a Member as well.
wibling-chromium
2014/05/27 11:16:36
Done.
| |
210 RefPtr<HTMLStackItem> m_contextElementStackItem; | 213 RefPtrWillBeMember<HTMLStackItem> m_contextElementStackItem; |
211 }; | 214 }; |
212 | 215 |
213 bool m_framesetOk; | 216 bool m_framesetOk; |
214 #ifndef NDEBUG | 217 #ifndef NDEBUG |
215 bool m_isAttached; | 218 bool m_isAttached; |
216 #endif | 219 #endif |
217 FragmentParsingContext m_fragmentContext; | 220 FragmentParsingContext m_fragmentContext; |
218 HTMLConstructionSite m_tree; | 221 HTMLConstructionSite m_tree; |
219 | 222 |
220 // http://www.whatwg.org/specs/web-apps/current-work/multipage/parsing.html# insertion-mode | 223 // http://www.whatwg.org/specs/web-apps/current-work/multipage/parsing.html# insertion-mode |
(...skipping 15 matching lines...) Expand all Loading... | |
236 | 239 |
237 RefPtrWillBeMember<Element> m_scriptToProcess; // <script> tag which needs p rocessing before resuming the parser. | 240 RefPtrWillBeMember<Element> m_scriptToProcess; // <script> tag which needs p rocessing before resuming the parser. |
238 TextPosition m_scriptToProcessStartPosition; // Starting line number of the script tag needing processing. | 241 TextPosition m_scriptToProcessStartPosition; // Starting line number of the script tag needing processing. |
239 | 242 |
240 HTMLParserOptions m_options; | 243 HTMLParserOptions m_options; |
241 }; | 244 }; |
242 | 245 |
243 } | 246 } |
244 | 247 |
245 #endif | 248 #endif |
OLD | NEW |