| 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 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 256 #endif | 256 #endif |
| 257 InstanceCounters::incrementCounter(InstanceCounters::NodeCounter); | 257 InstanceCounters::incrementCounter(InstanceCounters::NodeCounter); |
| 258 } | 258 } |
| 259 | 259 |
| 260 Node::~Node() | 260 Node::~Node() |
| 261 { | 261 { |
| 262 // With Oilpan, the rare data finalizer also asserts for | 262 // With Oilpan, the rare data finalizer also asserts for |
| 263 // this condition (we cannot directly access it here.) | 263 // this condition (we cannot directly access it here.) |
| 264 RELEASE_ASSERT(hasRareData() || !layoutObject()); | 264 RELEASE_ASSERT(hasRareData() || !layoutObject()); |
| 265 InstanceCounters::decrementCounter(InstanceCounters::NodeCounter); | 265 InstanceCounters::decrementCounter(InstanceCounters::NodeCounter); |
| 266 if (!hasRareData() && !hasLayoutObject() && m_data.m_computedStyle) | |
| 267 m_data.m_computedStyle->deref(); | |
| 268 } | 266 } |
| 269 | 267 |
| 270 NodeRareData* Node::rareData() const | 268 NodeRareData* Node::rareData() const |
| 271 { | 269 { |
| 272 ASSERT_WITH_SECURITY_IMPLICATION(hasRareData()); | 270 ASSERT_WITH_SECURITY_IMPLICATION(hasRareData()); |
| 273 return static_cast<NodeRareData*>(m_data.m_rareData); | 271 return static_cast<NodeRareData*>(m_data.m_rareData); |
| 274 } | 272 } |
| 275 | 273 |
| 276 NodeRareData& Node::ensureRareData() | 274 NodeRareData& Node::ensureRareData() |
| 277 { | 275 { |
| (...skipping 2207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2485 | 2483 |
| 2486 void showNodePath(const blink::Node* node) | 2484 void showNodePath(const blink::Node* node) |
| 2487 { | 2485 { |
| 2488 if (node) | 2486 if (node) |
| 2489 node->showNodePathForThis(); | 2487 node->showNodePathForThis(); |
| 2490 else | 2488 else |
| 2491 fprintf(stderr, "Cannot showNodePath for (nil)\n"); | 2489 fprintf(stderr, "Cannot showNodePath for (nil)\n"); |
| 2492 } | 2490 } |
| 2493 | 2491 |
| 2494 #endif | 2492 #endif |
| OLD | NEW |