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

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

Issue 1174823004: Unuse bitfields for ElementRareData::m_proxyCount. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: add comment Created 5 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
« no previous file with comments | « no previous file | no next file » | 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) 2008, 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2008, 2009, 2010 Apple Inc. All rights reserved.
3 * Copyright (C) 2008 David Smith <catfish.man@gmail.com> 3 * Copyright (C) 2008 David Smith <catfish.man@gmail.com>
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 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 CustomElementDefinition* customElementDefinition() const { return m_customEl ementDefinition.get(); } 122 CustomElementDefinition* customElementDefinition() const { return m_customEl ementDefinition.get(); }
123 123
124 AttrNodeList& ensureAttrNodeList(); 124 AttrNodeList& ensureAttrNodeList();
125 AttrNodeList* attrNodeList() { return m_attrNodeList.get(); } 125 AttrNodeList* attrNodeList() { return m_attrNodeList.get(); }
126 void removeAttrNodeList() { m_attrNodeList.clear(); } 126 void removeAttrNodeList() { m_attrNodeList.clear(); }
127 127
128 DECLARE_TRACE_AFTER_DISPATCH(); 128 DECLARE_TRACE_AFTER_DISPATCH();
129 129
130 private: 130 private:
131 short m_tabindex; 131 short m_tabindex;
132 unsigned short m_proxyCount : 10; 132 // As m_proxyCount usually doesn't exceed 10bits (1024), if you want to add some booleans you
133 // can steal some bits from m_proxyCount by using bitfields to prevent Eleme ntRareData bloat.
134 unsigned short m_proxyCount;
133 135
134 LayoutSize m_minimumSizeForResizing; 136 LayoutSize m_minimumSizeForResizing;
135 IntSize m_savedLayerScrollOffset; 137 IntSize m_savedLayerScrollOffset;
136 138
137 OwnPtrWillBeMember<DatasetDOMStringMap> m_dataset; 139 OwnPtrWillBeMember<DatasetDOMStringMap> m_dataset;
138 OwnPtrWillBeMember<ClassList> m_classList; 140 OwnPtrWillBeMember<ClassList> m_classList;
139 OwnPtrWillBeMember<ElementShadow> m_shadow; 141 OwnPtrWillBeMember<ElementShadow> m_shadow;
140 OwnPtrWillBeMember<NamedNodeMap> m_attributeMap; 142 OwnPtrWillBeMember<NamedNodeMap> m_attributeMap;
141 OwnPtrWillBeMember<AttrNodeList> m_attrNodeList; 143 OwnPtrWillBeMember<AttrNodeList> m_attrNodeList;
142 OwnPtrWillBeMember<ElementAnimations> m_elementAnimations; 144 OwnPtrWillBeMember<ElementAnimations> m_elementAnimations;
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 case FIRST_LETTER: 233 case FIRST_LETTER:
232 return m_generatedFirstLetter.get(); 234 return m_generatedFirstLetter.get();
233 default: 235 default:
234 return 0; 236 return 0;
235 } 237 }
236 } 238 }
237 239
238 } // namespace 240 } // namespace
239 241
240 #endif // ElementRareData_h 242 #endif // ElementRareData_h
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698