| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
| 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 29 */ | 29 */ |
| 30 | 30 |
| 31 #include "config.h" | 31 #include "config.h" |
| 32 #include "Init.h" | 32 #include "Init.h" |
| 33 | 33 |
| 34 #include "EventNames.h" | 34 #include "EventNames.h" |
| 35 #include "EventTargetModulesNames.h" | |
| 36 #include "EventTargetNames.h" | 35 #include "EventTargetNames.h" |
| 37 #include "EventTypeNames.h" | 36 #include "EventTypeNames.h" |
| 38 #include "FetchInitiatorTypeNames.h" | 37 #include "FetchInitiatorTypeNames.h" |
| 39 #include "FontFamilyNames.h" | 38 #include "FontFamilyNames.h" |
| 40 #include "HTMLNames.h" | 39 #include "HTMLNames.h" |
| 41 #include "HTMLTokenizerNames.h" | 40 #include "HTMLTokenizerNames.h" |
| 42 #include "InputTypeNames.h" | 41 #include "InputTypeNames.h" |
| 43 #include "MathMLNames.h" | 42 #include "MathMLNames.h" |
| 44 #include "MediaFeatureNames.h" | 43 #include "MediaFeatureNames.h" |
| 45 #include "MediaTypeNames.h" | 44 #include "MediaTypeNames.h" |
| 46 #include "SVGNames.h" | 45 #include "SVGNames.h" |
| 47 #include "XLinkNames.h" | 46 #include "XLinkNames.h" |
| 48 #include "XMLNSNames.h" | 47 #include "XMLNSNames.h" |
| 49 #include "XMLNames.h" | 48 #include "XMLNames.h" |
| 50 #include "core/html/parser/HTMLParserThread.h" | 49 #include "core/html/parser/HTMLParserThread.h" |
| 51 #include "platform/EventTracer.h" | 50 #include "platform/EventTracer.h" |
| 52 #include "platform/Partitions.h" | 51 #include "platform/Partitions.h" |
| 53 #include "platform/PlatformThreadData.h" | 52 #include "platform/PlatformThreadData.h" |
| 54 #include "platform/heap/Heap.h" | 53 #include "platform/heap/Heap.h" |
| 55 #include "wtf/text/StringStatics.h" | 54 #include "wtf/text/StringStatics.h" |
| 56 | 55 |
| 57 namespace WebCore { | 56 namespace WebCore { |
| 58 | 57 |
| 59 void init() | 58 void CoreInitializer::initEventTargetNames() |
| 60 { | 59 { |
| 61 static bool isInited; | 60 EventTargetNames::init(); |
| 62 if (isInited) | 61 } |
| 62 |
| 63 void CoreInitializer::init() |
| 64 { |
| 65 if (m_isInited) |
| 63 return; | 66 return; |
| 64 isInited = true; | 67 m_isInited = true; |
| 65 | 68 |
| 66 // It would make logical sense to do this and WTF::StringStatics::init() in | 69 // It would make logical sense to do this and WTF::StringStatics::init() in |
| 67 // WTF::initialize() but there are ordering dependencies. | 70 // WTF::initialize() but there are ordering dependencies. |
| 68 AtomicString::init(); | 71 AtomicString::init(); |
| 69 HTMLNames::init(); | 72 HTMLNames::init(); |
| 70 SVGNames::init(); | 73 SVGNames::init(); |
| 71 XLinkNames::init(); | 74 XLinkNames::init(); |
| 72 MathMLNames::init(); | 75 MathMLNames::init(); |
| 73 XMLNSNames::init(); | 76 XMLNSNames::init(); |
| 74 XMLNames::init(); | 77 XMLNames::init(); |
| 75 | 78 |
| 76 EventNames::init(); | 79 EventNames::init(); |
| 77 EventTargetNames::init(); | 80 initEventTargetNames(); |
| 78 EventTargetNames::initModules(); // TODO: remove this later http://crbug.com
/371581. | |
| 79 EventTypeNames::init(); | 81 EventTypeNames::init(); |
| 80 FetchInitiatorTypeNames::init(); | 82 FetchInitiatorTypeNames::init(); |
| 81 FontFamilyNames::init(); | 83 FontFamilyNames::init(); |
| 82 HTMLTokenizerNames::init(); | 84 HTMLTokenizerNames::init(); |
| 83 InputTypeNames::init(); | 85 InputTypeNames::init(); |
| 84 MediaFeatureNames::init(); | 86 MediaFeatureNames::init(); |
| 85 MediaTypeNames::init(); | 87 MediaTypeNames::init(); |
| 86 | 88 |
| 87 WTF::StringStatics::init(); | 89 WTF::StringStatics::init(); |
| 88 QualifiedName::init(); | 90 QualifiedName::init(); |
| (...skipping 12 matching lines...) Expand all Loading... |
| 101 | 103 |
| 102 void shutdown() | 104 void shutdown() |
| 103 { | 105 { |
| 104 // Make sure we stop the HTMLParserThread before Platform::current() is clea
red. | 106 // Make sure we stop the HTMLParserThread before Platform::current() is clea
red. |
| 105 HTMLParserThread::shutdown(); | 107 HTMLParserThread::shutdown(); |
| 106 | 108 |
| 107 Partitions::shutdown(); | 109 Partitions::shutdown(); |
| 108 } | 110 } |
| 109 | 111 |
| 110 } // namespace WebCore | 112 } // namespace WebCore |
| OLD | NEW |