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

Side by Side Diff: third_party/WebKit/Source/core/html/CollectionItemsCache.h

Issue 1406923009: Rename DISALLOW_ALLOCATION and ALLOW_ONLY_INLINE_ALLOCATION (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012,2013 Google Inc. All rights reserved. 2 * Copyright (C) 2012,2013 Google Inc. All rights reserved.
3 * Copyright (C) 2014 Apple Inc. All rights reserved. 3 * Copyright (C) 2014 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 22 matching lines...) Expand all
33 #define CollectionItemsCache_h 33 #define CollectionItemsCache_h
34 34
35 #include "core/html/CollectionIndexCache.h" 35 #include "core/html/CollectionIndexCache.h"
36 #include "wtf/Vector.h" 36 #include "wtf/Vector.h"
37 #include <v8.h> 37 #include <v8.h>
38 38
39 namespace blink { 39 namespace blink {
40 40
41 template <typename Collection, typename NodeType> 41 template <typename Collection, typename NodeType>
42 class CollectionItemsCache : public CollectionIndexCache<Collection, NodeType> { 42 class CollectionItemsCache : public CollectionIndexCache<Collection, NodeType> {
43 DISALLOW_ALLOCATION(); 43 DISALLOW_NEW();
44 44
45 typedef CollectionIndexCache<Collection, NodeType> Base; 45 typedef CollectionIndexCache<Collection, NodeType> Base;
46 46
47 public: 47 public:
48 CollectionItemsCache(); 48 CollectionItemsCache();
49 ~CollectionItemsCache(); 49 ~CollectionItemsCache();
50 50
51 DEFINE_INLINE_VIRTUAL_TRACE() 51 DEFINE_INLINE_VIRTUAL_TRACE()
52 { 52 {
53 visitor->trace(m_cachedList); 53 visitor->trace(m_cachedList);
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 if (m_listValid) { 119 if (m_listValid) {
120 ASSERT(this->isCachedNodeCountValid()); 120 ASSERT(this->isCachedNodeCountValid());
121 return index < this->cachedNodeCount() ? m_cachedList[index] : nullptr; 121 return index < this->cachedNodeCount() ? m_cachedList[index] : nullptr;
122 } 122 }
123 return Base::nodeAt(collection, index); 123 return Base::nodeAt(collection, index);
124 } 124 }
125 125
126 } // namespace blink 126 } // namespace blink
127 127
128 #endif // CollectionItemsCache_h 128 #endif // CollectionItemsCache_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/CollectionIndexCache.h ('k') | third_party/WebKit/Source/core/html/HTMLDimension.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698