Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 53 public: | 53 public: |
| 54 static ElementRareData* create(LayoutObject* layoutObject) { | 54 static ElementRareData* create(LayoutObject* layoutObject) { |
| 55 return new ElementRareData(layoutObject); | 55 return new ElementRareData(layoutObject); |
| 56 } | 56 } |
| 57 | 57 |
| 58 ~ElementRareData(); | 58 ~ElementRareData(); |
| 59 | 59 |
| 60 void setPseudoElement(PseudoId, PseudoElement*); | 60 void setPseudoElement(PseudoId, PseudoElement*); |
| 61 PseudoElement* pseudoElement(PseudoId) const; | 61 PseudoElement* pseudoElement(PseudoId) const; |
| 62 | 62 |
| 63 short tabIndex() const { return m_tabindex; } | 63 void setTabIndexExplicitly(int index) { |
|
kochi
2016/11/04 06:49:35
You can remove the parameter here.
rwlbuis
2016/11/04 13:03:18
Done.
| |
| 64 | |
| 65 void setTabIndexExplicitly(short index) { | |
| 66 m_tabindex = index; | |
| 67 setElementFlag(TabIndexWasSetExplicitly, true); | 64 setElementFlag(TabIndexWasSetExplicitly, true); |
| 68 } | 65 } |
| 69 | 66 |
| 70 void clearTabIndexExplicitly() { | 67 void clearTabIndexExplicitly() { |
| 71 m_tabindex = 0; | |
| 72 clearElementFlag(TabIndexWasSetExplicitly); | 68 clearElementFlag(TabIndexWasSetExplicitly); |
| 73 } | 69 } |
| 74 | 70 |
| 75 CSSStyleDeclaration& ensureInlineCSSStyleDeclaration(Element* ownerElement); | 71 CSSStyleDeclaration& ensureInlineCSSStyleDeclaration(Element* ownerElement); |
| 76 InlineStylePropertyMap& ensureInlineStylePropertyMap(Element* ownerElement); | 72 InlineStylePropertyMap& ensureInlineStylePropertyMap(Element* ownerElement); |
| 77 | 73 |
| 78 InlineStylePropertyMap* inlineStylePropertyMap() { | 74 InlineStylePropertyMap* inlineStylePropertyMap() { |
| 79 return m_cssomMapWrapper.get(); | 75 return m_cssomMapWrapper.get(); |
| 80 } | 76 } |
| 81 | 77 |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 185 } | 181 } |
| 186 ResizeObserverDataMap& ensureResizeObserverData(); | 182 ResizeObserverDataMap& ensureResizeObserverData(); |
| 187 | 183 |
| 188 DECLARE_TRACE_AFTER_DISPATCH(); | 184 DECLARE_TRACE_AFTER_DISPATCH(); |
| 189 DECLARE_TRACE_WRAPPERS_AFTER_DISPATCH(); | 185 DECLARE_TRACE_WRAPPERS_AFTER_DISPATCH(); |
| 190 | 186 |
| 191 private: | 187 private: |
| 192 CompositorProxiedPropertySet& ensureCompositorProxiedPropertySet(); | 188 CompositorProxiedPropertySet& ensureCompositorProxiedPropertySet(); |
| 193 void clearCompositorProxiedPropertySet() { m_proxiedProperties = nullptr; } | 189 void clearCompositorProxiedPropertySet() { m_proxiedProperties = nullptr; } |
| 194 | 190 |
| 195 short m_tabindex; | |
|
kochi
2016/11/04 06:49:35
Didn't you get any error for SameSizeAsElementRare
kochi
2016/11/04 07:17:04
I figured out.
The last member of NodeRareData (wh
rwlbuis
2016/11/04 13:03:18
Thanks for looking into it, I forgot about this. I
rwlbuis
2016/11/04 13:03:18
Acknowledged.
| |
| 196 | |
| 197 LayoutSize m_minimumSizeForResizing; | 191 LayoutSize m_minimumSizeForResizing; |
| 198 ScrollOffset m_savedLayerScrollOffset; | 192 ScrollOffset m_savedLayerScrollOffset; |
| 199 | 193 |
| 200 Member<DatasetDOMStringMap> m_dataset; | 194 Member<DatasetDOMStringMap> m_dataset; |
| 201 Member<ElementShadow> m_shadow; | 195 Member<ElementShadow> m_shadow; |
| 202 Member<ClassList> m_classList; | 196 Member<ClassList> m_classList; |
| 203 Member<NamedNodeMap> m_attributeMap; | 197 Member<NamedNodeMap> m_attributeMap; |
| 204 Member<AttrNodeList> m_attrNodeList; | 198 Member<AttrNodeList> m_attrNodeList; |
| 205 Member<InlineCSSStyleDeclaration> m_cssomWrapper; | 199 Member<InlineCSSStyleDeclaration> m_cssomWrapper; |
| 206 Member<InlineStylePropertyMap> m_cssomMapWrapper; | 200 Member<InlineStylePropertyMap> m_cssomMapWrapper; |
| (...skipping 12 matching lines...) Expand all Loading... | |
| 219 | 213 |
| 220 explicit ElementRareData(LayoutObject*); | 214 explicit ElementRareData(LayoutObject*); |
| 221 }; | 215 }; |
| 222 | 216 |
| 223 inline LayoutSize defaultMinimumSizeForResizing() { | 217 inline LayoutSize defaultMinimumSizeForResizing() { |
| 224 return LayoutSize(LayoutUnit::max(), LayoutUnit::max()); | 218 return LayoutSize(LayoutUnit::max(), LayoutUnit::max()); |
| 225 } | 219 } |
| 226 | 220 |
| 227 inline ElementRareData::ElementRareData(LayoutObject* layoutObject) | 221 inline ElementRareData::ElementRareData(LayoutObject* layoutObject) |
| 228 : NodeRareData(layoutObject), | 222 : NodeRareData(layoutObject), |
| 229 m_tabindex(0), | |
| 230 m_minimumSizeForResizing(defaultMinimumSizeForResizing()), | 223 m_minimumSizeForResizing(defaultMinimumSizeForResizing()), |
| 231 m_classList(nullptr) { | 224 m_classList(nullptr) { |
| 232 m_isElementRareData = true; | 225 m_isElementRareData = true; |
| 233 } | 226 } |
| 234 | 227 |
| 235 inline ElementRareData::~ElementRareData() { | 228 inline ElementRareData::~ElementRareData() { |
| 236 DCHECK(!m_pseudoElementData); | 229 DCHECK(!m_pseudoElementData); |
| 237 } | 230 } |
| 238 | 231 |
| 239 inline bool ElementRareData::hasPseudoElements() const { | 232 inline bool ElementRareData::hasPseudoElements() const { |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 275 inline CompositorProxiedPropertySet& | 268 inline CompositorProxiedPropertySet& |
| 276 ElementRareData::ensureCompositorProxiedPropertySet() { | 269 ElementRareData::ensureCompositorProxiedPropertySet() { |
| 277 if (!m_proxiedProperties) | 270 if (!m_proxiedProperties) |
| 278 m_proxiedProperties = CompositorProxiedPropertySet::create(); | 271 m_proxiedProperties = CompositorProxiedPropertySet::create(); |
| 279 return *m_proxiedProperties; | 272 return *m_proxiedProperties; |
| 280 } | 273 } |
| 281 | 274 |
| 282 } // namespace blink | 275 } // namespace blink |
| 283 | 276 |
| 284 #endif // ElementRareData_h | 277 #endif // ElementRareData_h |
| OLD | NEW |