Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(38)

Side by Side Diff: Source/core/html/HTMLFrameSetElement.cpp

Issue 16896019: Replace RenderArena with PartitionAlloc. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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) 2000 Simon Hausmann (hausmann@kde.org) 4 * (C) 2000 Simon Hausmann (hausmann@kde.org)
5 * (C) 2001 Dirk Mueller (mueller@kde.org) 5 * (C) 2001 Dirk Mueller (mueller@kde.org)
6 * Copyright (C) 2004, 2006, 2009, 2010 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2006, 2009, 2010 Apple Inc. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
149 HTMLElement::parseAttribute(name, value); 149 HTMLElement::parseAttribute(name, value);
150 } 150 }
151 151
152 bool HTMLFrameSetElement::rendererIsNeeded(const NodeRenderingContext& context) 152 bool HTMLFrameSetElement::rendererIsNeeded(const NodeRenderingContext& context)
153 { 153 {
154 // For compatibility, frames render even when display: none is set. 154 // For compatibility, frames render even when display: none is set.
155 // However, we delay creating a renderer until stylesheets have loaded. 155 // However, we delay creating a renderer until stylesheets have loaded.
156 return context.style()->isStyleAvailable(); 156 return context.style()->isStyleAvailable();
157 } 157 }
158 158
159 RenderObject *HTMLFrameSetElement::createRenderer(RenderArena *arena, RenderStyl e *style) 159 RenderObject* HTMLFrameSetElement::createRenderer(RenderStyle *style)
160 { 160 {
161 if (style->hasContent()) 161 if (style->hasContent())
162 return RenderObject::createObject(this, style); 162 return RenderObject::createObject(this, style);
163 163
164 return new (arena) RenderFrameSet(this); 164 return new RenderFrameSet(this);
165 } 165 }
166 166
167 void HTMLFrameSetElement::attach(const AttachContext& context) 167 void HTMLFrameSetElement::attach(const AttachContext& context)
168 { 168 {
169 // Inherit default settings from parent frameset 169 // Inherit default settings from parent frameset
170 // FIXME: This is not dynamic. 170 // FIXME: This is not dynamic.
171 for (ContainerNode* node = parentNode(); node; node = node->parentNode()) { 171 for (ContainerNode* node = parentNode(); node; node = node->parentNode()) {
172 if (node->hasTagName(framesetTag)) { 172 if (node->hasTagName(framesetTag)) {
173 HTMLFrameSetElement* frameset = static_cast<HTMLFrameSetElement*>(no de); 173 HTMLFrameSetElement* frameset = static_cast<HTMLFrameSetElement*>(no de);
174 if (!m_frameborderSet) 174 if (!m_frameborderSet)
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 Node* frameNode = children()->namedItem(name); 221 Node* frameNode = children()->namedItem(name);
222 if (!frameNode || !frameNode->hasTagName(HTMLNames::frameTag)) 222 if (!frameNode || !frameNode->hasTagName(HTMLNames::frameTag))
223 return 0; 223 return 0;
224 Document* document = static_cast<HTMLFrameElement*>(frameNode)->contentDocum ent(); 224 Document* document = static_cast<HTMLFrameElement*>(frameNode)->contentDocum ent();
225 if (!document || !document->frame()) 225 if (!document || !document->frame())
226 return 0; 226 return 0;
227 return document->domWindow(); 227 return document->domWindow();
228 } 228 }
229 229
230 } // namespace WebCore 230 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698