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

Side by Side Diff: Source/core/dom/ContainerNode.h

Issue 14449003: Picture element initial implementation (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@picture_after_rebase
Patch Set: Created 7 years, 8 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
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/dom/Element.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved. 5 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 ContainerNode* parent = parentOrShadowHostNode(); 259 ContainerNode* parent = parentOrShadowHostNode();
260 return parent && parent->getFlag(NeedsShadowTreeWalkerFlag); 260 return parent && parent->getFlag(NeedsShadowTreeWalkerFlag);
261 } 261 }
262 262
263 // This constant controls how much buffer is initially allocated 263 // This constant controls how much buffer is initially allocated
264 // for a Node Vector that is used to store child Nodes of a given Node. 264 // for a Node Vector that is used to store child Nodes of a given Node.
265 // FIXME: Optimize the value. 265 // FIXME: Optimize the value.
266 const int initialNodeVectorSize = 11; 266 const int initialNodeVectorSize = 11;
267 typedef Vector<RefPtr<Node>, initialNodeVectorSize> NodeVector; 267 typedef Vector<RefPtr<Node>, initialNodeVectorSize> NodeVector;
268 268
269 inline void getChildNodes(Node* node, NodeVector& nodes) 269 inline void getChildNodes(const Node* node, NodeVector& nodes)
270 { 270 {
271 ASSERT(!nodes.size()); 271 ASSERT(!nodes.size());
272 for (Node* child = node->firstChild(); child; child = child->nextSibling()) 272 for (Node* child = node->firstChild(); child; child = child->nextSibling())
273 nodes.append(child); 273 nodes.append(child);
274 } 274 }
275 275
276 class ChildNodesLazySnapshot { 276 class ChildNodesLazySnapshot {
277 WTF_MAKE_NONCOPYABLE(ChildNodesLazySnapshot); 277 WTF_MAKE_NONCOPYABLE(ChildNodesLazySnapshot);
278 WTF_MAKE_FAST_ALLOCATED; 278 WTF_MAKE_FAST_ALLOCATED;
279 public: 279 public:
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
352 m_node->resumePostAttachCallbacks(); 352 m_node->resumePostAttachCallbacks();
353 } 353 }
354 354
355 private: 355 private:
356 ContainerNode* m_node; 356 ContainerNode* m_node;
357 }; 357 };
358 358
359 } // namespace WebCore 359 } // namespace WebCore
360 360
361 #endif // ContainerNode_h 361 #endif // ContainerNode_h
OLDNEW
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/dom/Element.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698