| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. |
| 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| 7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 #include "core/inspector/InspectorCounters.h" | 97 #include "core/inspector/InspectorCounters.h" |
| 98 #include "core/page/Chrome.h" | 98 #include "core/page/Chrome.h" |
| 99 #include "core/page/ChromeClient.h" | 99 #include "core/page/ChromeClient.h" |
| 100 #include "core/page/ContextMenuController.h" | 100 #include "core/page/ContextMenuController.h" |
| 101 #include "core/page/EventHandler.h" | 101 #include "core/page/EventHandler.h" |
| 102 #include "core/page/Frame.h" | 102 #include "core/page/Frame.h" |
| 103 #include "core/page/FrameView.h" | 103 #include "core/page/FrameView.h" |
| 104 #include "core/page/Page.h" | 104 #include "core/page/Page.h" |
| 105 #include "core/page/Settings.h" | 105 #include "core/page/Settings.h" |
| 106 #include "core/platform/Logging.h" | 106 #include "core/platform/Logging.h" |
| 107 #include "core/platform/Partitions.h" |
| 107 #include "core/platform/PlatformMouseEvent.h" | 108 #include "core/platform/PlatformMouseEvent.h" |
| 108 #include "core/platform/PlatformWheelEvent.h" | 109 #include "core/platform/PlatformWheelEvent.h" |
| 109 #include "core/rendering/RenderBlock.h" | 110 #include "core/rendering/RenderBlock.h" |
| 110 #include "core/rendering/RenderBox.h" | 111 #include "core/rendering/RenderBox.h" |
| 111 #include "core/rendering/RenderTextControl.h" | 112 #include "core/rendering/RenderTextControl.h" |
| 112 #include "core/rendering/RenderView.h" | 113 #include "core/rendering/RenderView.h" |
| 113 #include "core/storage/StorageEvent.h" | 114 #include "core/storage/StorageEvent.h" |
| 114 #include "wtf/HashSet.h" | 115 #include "wtf/HashSet.h" |
| 115 #include "wtf/PartitionAlloc.h" | |
| 116 #include "wtf/PassOwnPtr.h" | 116 #include "wtf/PassOwnPtr.h" |
| 117 #include "wtf/RefCountedLeakCounter.h" | 117 #include "wtf/RefCountedLeakCounter.h" |
| 118 #include "wtf/UnusedParam.h" | 118 #include "wtf/UnusedParam.h" |
| 119 #include "wtf/Vector.h" | 119 #include "wtf/Vector.h" |
| 120 #include "wtf/text/CString.h" | 120 #include "wtf/text/CString.h" |
| 121 #include "wtf/text/StringBuilder.h" | 121 #include "wtf/text/StringBuilder.h" |
| 122 | 122 |
| 123 #ifndef NDEBUG | 123 #ifndef NDEBUG |
| 124 #include "core/rendering/RenderLayer.h" | 124 #include "core/rendering/RenderLayer.h" |
| 125 #endif | 125 #endif |
| 126 | 126 |
| 127 using namespace std; | 127 using namespace std; |
| 128 | 128 |
| 129 namespace WebCore { | 129 namespace WebCore { |
| 130 | 130 |
| 131 using namespace HTMLNames; | 131 using namespace HTMLNames; |
| 132 | 132 |
| 133 #if ENABLE(PARTITION_ALLOC) | 133 #if ENABLE(PARTITION_ALLOC) |
| 134 static PartitionRoot root; | |
| 135 | |
| 136 void* Node::operator new(size_t size) | 134 void* Node::operator new(size_t size) |
| 137 { | 135 { |
| 138 return partitionAlloc(&root, size); | 136 return partitionAlloc(Partitions::getObjectModelPartition(), size); |
| 139 } | 137 } |
| 140 | 138 |
| 141 void Node::operator delete(void* ptr) | 139 void Node::operator delete(void* ptr) |
| 142 { | 140 { |
| 143 partitionFree(ptr); | 141 partitionFree(ptr); |
| 144 } | 142 } |
| 145 #endif // ENABLE(PARTITION_ALLOC) | 143 #endif // ENABLE(PARTITION_ALLOC) |
| 146 | 144 |
| 147 void Node::init() | |
| 148 { | |
| 149 #if ENABLE(PARTITION_ALLOC) | |
| 150 partitionAllocInit(&root); | |
| 151 #endif | |
| 152 } | |
| 153 | |
| 154 void Node::shutdown() | |
| 155 { | |
| 156 #if ENABLE(PARTITION_ALLOC) | |
| 157 partitionAllocShutdown(&root); | |
| 158 #endif | |
| 159 } | |
| 160 | |
| 161 bool Node::isSupported(const String& feature, const String& version) | 145 bool Node::isSupported(const String& feature, const String& version) |
| 162 { | 146 { |
| 163 return DOMImplementation::hasFeature(feature, version); | 147 return DOMImplementation::hasFeature(feature, version); |
| 164 } | 148 } |
| 165 | 149 |
| 166 #if DUMP_NODE_STATISTICS | 150 #if DUMP_NODE_STATISTICS |
| 167 static HashSet<Node*> liveNodeSet; | 151 static HashSet<Node*> liveNodeSet; |
| 168 #endif | 152 #endif |
| 169 | 153 |
| 170 void Node::dumpStatistics() | 154 void Node::dumpStatistics() |
| (...skipping 2595 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2766 node->showTreeForThis(); | 2750 node->showTreeForThis(); |
| 2767 } | 2751 } |
| 2768 | 2752 |
| 2769 void showNodePath(const WebCore::Node* node) | 2753 void showNodePath(const WebCore::Node* node) |
| 2770 { | 2754 { |
| 2771 if (node) | 2755 if (node) |
| 2772 node->showNodePathForThis(); | 2756 node->showNodePathForThis(); |
| 2773 } | 2757 } |
| 2774 | 2758 |
| 2775 #endif | 2759 #endif |
| OLD | NEW |