| 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 { |
| 358 if (m_counterNode) { | 362 if (m_counterNode) { |
| 359 m_counterNode->removeRenderer(this); | 363 m_counterNode->removeRenderer(this); |
| 360 ASSERT(!m_counterNode); | 364 ASSERT(!m_counterNode); |
| 361 } | 365 } |
| 366 RenderText::destroy(); |
| 362 } | 367 } |
| 363 | 368 |
| 364 void RenderCounter::willBeDestroyed() | 369 void RenderCounter::willBeDestroyed() |
| 365 { | 370 { |
| 366 if (view()) | 371 if (view()) |
| 367 view()->removeRenderCounter(); | 372 view()->removeRenderCounter(); |
| 368 RenderText::willBeDestroyed(); | 373 RenderText::willBeDestroyed(); |
| 369 } | 374 } |
| 370 | 375 |
| 371 const char* RenderCounter::renderName() const | 376 const char* RenderCounter::renderName() const |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 608 fprintf(stderr, " "); | 613 fprintf(stderr, " "); |
| 609 fprintf(stderr, "%p N:%p P:%p PS:%p NS:%p C:%p\n", | 614 fprintf(stderr, "%p N:%p P:%p PS:%p NS:%p C:%p\n", |
| 610 current, current->node(), current->parent(), current->previousSiblin
g(), | 615 current, current->node(), current->parent(), current->previousSiblin
g(), |
| 611 current->nextSibling(), current->hasCounterNodeMap() ? | 616 current->nextSibling(), current->hasCounterNodeMap() ? |
| 612 counterName ? blink::counterMaps().get(current)->get(identifier) : (
blink::CounterNode*)1 : (blink::CounterNode*)0); | 617 counterName ? blink::counterMaps().get(current)->get(identifier) : (
blink::CounterNode*)1 : (blink::CounterNode*)0); |
| 613 } | 618 } |
| 614 fflush(stderr); | 619 fflush(stderr); |
| 615 } | 620 } |
| 616 | 621 |
| 617 #endif // NDEBUG | 622 #endif // NDEBUG |
| OLD | NEW |