From 2a3569183f13cadd01db35cacddd4c8d60169aa6 Mon Sep 17 00:00:00 2001 From: Cary Clark Date: Mon, 20 Apr 2009 10:43:59 -0400 Subject: remove obsolete browser nav cache debug dump The render tree has changed and the old dump logic no longer compiles. This output isn't used anymore, so remove it. --- WebKit/android/nav/CacheBuilder.cpp | 61 ------------------------------------- WebKit/android/nav/CacheBuilder.h | 1 - 2 files changed, 62 deletions(-) diff --git a/WebKit/android/nav/CacheBuilder.cpp b/WebKit/android/nav/CacheBuilder.cpp index 05d1cb5..bf10a4d 100644 --- a/WebKit/android/nav/CacheBuilder.cpp +++ b/WebKit/android/nav/CacheBuilder.cpp @@ -457,8 +457,6 @@ void CacheBuilder::Debug::groups() { } } } - if (renderer) - renderTree(renderer, 0, node, count); count++; newLine(); } while ((node = node->traverseNextNode()) != NULL); @@ -653,65 +651,6 @@ void CacheBuilder::Debug::setIndent(int indent) print(scratch); } -void CacheBuilder::Debug::renderTree(RenderObject* renderer, int indent, - Node* child, int count) -{ - char scratch[256]; - Node* node = renderer->node(); - if (node != child) { - count = ParentIndex(child, count, node); - if (renderer->isRenderBlock() == false) - goto tryParent; - RenderBlock* renderBlock = (RenderBlock*) renderer; - if (renderBlock->hasColumns() == false) - goto tryParent; - Vector* rects = renderBlock->columnRects(); - newLine(indent); - snprintf(scratch, sizeof(scratch), "// render parent=%d", count); - print(scratch); - for (size_t x = 0; x < rects->size(); x++) { - const IntRect& rect = rects->at(x); - snprintf(scratch, sizeof(scratch), "(%d,%d,%d,%d) ", rect.x(), - rect.y(), rect.width(), rect.height()); - print(scratch); - } - } - { - newLine(indent); - RenderStyle* style = renderer->style(); - EVisibility vis = style->visibility(); - ASSERT(vis == VISIBLE || vis == HIDDEN || vis == COLLAPSE); - snprintf(scratch, sizeof(scratch), - "// render style visible:%s opacity:%g width:%d height:%d" - " hasBackground:%s isInlineFlow:%s isBlockFlow:%s" - " textOverflow:%s", - vis == VISIBLE ? "visible" : vis == HIDDEN ? "hidden" : "collapse", - style->opacity(), 0 /*renderer->width()*/, 0 /*renderer->height()*/, - style->hasBackground() ? "true" : "false", - 0 /*renderer->isInlineFlow()*/ ? "true" : "false", - renderer->isBlockFlow() ? "true" : "false", - style->textOverflow() ? "true" : "false" - ); - print(scratch); - newLine(indent); - const IntRect& oRect = renderer->absoluteClippedOverflowRect(); - RenderBox* box = toRenderBox(renderer); - const IntRect& cRect = box->overflowClipRect(0,0); - snprintf(scratch, sizeof(scratch), - "// render xPos:%d yPos:%d overflowRect:{%d, %d, %d, %d} " - " getOverflowClipRect:{%d, %d, %d, %d} ", - 0 /*renderer->xPos()*/, 0 /*renderer->yPos()*/, - oRect.x(), oRect.y(), oRect.width(), oRect.height(), - cRect.x(), cRect.y(), cRect.width(), cRect.height() - ); - print(scratch); - } -tryParent: - RenderObject* parent = renderer->parent(); - if (parent) - renderTree(parent, indent + 2, node, count); -} - void CacheBuilder::Debug::uChar(const UChar* name, unsigned len, bool hex) { const UChar* end = name + len; bool wroteHex = false; diff --git a/WebKit/android/nav/CacheBuilder.h b/WebKit/android/nav/CacheBuilder.h index dbed6e8..8152fa2 100644 --- a/WebKit/android/nav/CacheBuilder.h +++ b/WebKit/android/nav/CacheBuilder.h @@ -253,7 +253,6 @@ private: void localName(Node* node); void newLine(int indent = 0); void print(const char* name, unsigned len); - void renderTree(RenderObject* , int indent, Node* , int count); void setIndent(int ); void uChar(const UChar* name, unsigned len, bool hex); void validateFrame(); -- cgit v1.1