| OLD | NEW |
| 1 /** | 1 /** |
| 2 * Copyright (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) | 2 * Copyright (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) |
| 3 * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. | 3 * Copyright (C) 2006, 2007 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 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 348 : RenderText(node, StringImpl::empty()) | 348 : RenderText(node, StringImpl::empty()) |
| 349 , m_counter(counter) | 349 , m_counter(counter) |
| 350 , m_counterNode(0) | 350 , m_counterNode(0) |
| 351 , m_nextForSameCounter(0) | 351 , m_nextForSameCounter(0) |
| 352 { | 352 { |
| 353 view()->addRenderCounter(); | 353 view()->addRenderCounter(); |
| 354 } | 354 } |
| 355 | 355 |
| 356 RenderCounter::~RenderCounter() | 356 RenderCounter::~RenderCounter() |
| 357 { | 357 { |
| 358 } | |
| 359 | |
| 360 void RenderCounter::destroy() | |
| 361 { | |
| 362 if (m_counterNode) { | 358 if (m_counterNode) { |
| 363 m_counterNode->removeRenderer(this); | 359 m_counterNode->removeRenderer(this); |
| 364 ASSERT(!m_counterNode); | 360 ASSERT(!m_counterNode); |
| 365 } | 361 } |
| 366 RenderText::destroy(); | |
| 367 } | 362 } |
| 368 | 363 |
| 369 void RenderCounter::willBeDestroyed() | 364 void RenderCounter::willBeDestroyed() |
| 370 { | 365 { |
| 371 if (view()) | 366 if (view()) |
| 372 view()->removeRenderCounter(); | 367 view()->removeRenderCounter(); |
| 373 RenderText::willBeDestroyed(); | 368 RenderText::willBeDestroyed(); |
| 374 } | 369 } |
| 375 | 370 |
| 376 const char* RenderCounter::renderName() const | 371 const char* RenderCounter::renderName() const |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 613 fprintf(stderr, " "); | 608 fprintf(stderr, " "); |
| 614 fprintf(stderr, "%p N:%p P:%p PS:%p NS:%p C:%p\n", | 609 fprintf(stderr, "%p N:%p P:%p PS:%p NS:%p C:%p\n", |
| 615 current, current->node(), current->parent(), current->previousSiblin
g(), | 610 current, current->node(), current->parent(), current->previousSiblin
g(), |
| 616 current->nextSibling(), current->hasCounterNodeMap() ? | 611 current->nextSibling(), current->hasCounterNodeMap() ? |
| 617 counterName ? blink::counterMaps().get(current)->get(identifier) : (
blink::CounterNode*)1 : (blink::CounterNode*)0); | 612 counterName ? blink::counterMaps().get(current)->get(identifier) : (
blink::CounterNode*)1 : (blink::CounterNode*)0); |
| 618 } | 613 } |
| 619 fflush(stderr); | 614 fflush(stderr); |
| 620 } | 615 } |
| 621 | 616 |
| 622 #endif // NDEBUG | 617 #endif // NDEBUG |
| OLD | NEW |