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

Side by Side Diff: third_party/WebKit/Source/core/style/ComputedStyle.h

Issue 2699843002: Remove ComputedStyleBase::setBitsDefault(). (Closed)
Patch Set: Address comments Created 3 years, 10 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) 3 * (C) 2000 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All 5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All
6 * rights reserved. 6 * rights reserved.
7 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) 7 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com)
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 unsigned m_isLink : 1; 283 unsigned m_isLink : 1;
284 284
285 mutable unsigned m_hasRemUnits : 1; 285 mutable unsigned m_hasRemUnits : 1;
286 286
287 // If you add more style bits here, you will also need to update 287 // If you add more style bits here, you will also need to update
288 // ComputedStyle::copyNonInheritedFromCached() 68 bits 288 // ComputedStyle::copyNonInheritedFromCached() 68 bits
289 } m_nonInheritedData; 289 } m_nonInheritedData;
290 290
291 // !END SYNC! 291 // !END SYNC!
292 292
293 void setBitDefaults() { 293 // Only call inside the constructor. Generated properties in the base class
294 // Generated properties are updated in ComputedStyleBase 294 // are not initialized in this method.
295 ComputedStyleBase::setBitDefaults(); 295 void initializeBitDefaults() {
296 m_inheritedData.m_hasSimpleUnderline = false; 296 m_inheritedData.m_hasSimpleUnderline = false;
297 m_inheritedData.m_cursorStyle = static_cast<unsigned>(initialCursor()); 297 m_inheritedData.m_cursorStyle = static_cast<unsigned>(initialCursor());
298 m_inheritedData.m_insideLink = 298 m_inheritedData.m_insideLink =
299 static_cast<unsigned>(EInsideLink::kNotInsideLink); 299 static_cast<unsigned>(EInsideLink::kNotInsideLink);
300 300
301 m_nonInheritedData.m_effectiveDisplay = 301 m_nonInheritedData.m_effectiveDisplay =
302 m_nonInheritedData.m_originalDisplay = 302 m_nonInheritedData.m_originalDisplay =
303 static_cast<unsigned>(initialDisplay()); 303 static_cast<unsigned>(initialDisplay());
304 m_nonInheritedData.m_verticalAlign = 304 m_nonInheritedData.m_verticalAlign =
305 static_cast<unsigned>(initialVerticalAlign()); 305 static_cast<unsigned>(initialVerticalAlign());
(...skipping 3541 matching lines...) Expand 10 before | Expand all | Expand 10 after
3847 m_nonInheritedData.m_pseudoBits |= 1 << (pseudo - 1); 3847 m_nonInheritedData.m_pseudoBits |= 1 << (pseudo - 1);
3848 } 3848 }
3849 3849
3850 inline bool ComputedStyle::hasPseudoElementStyle() const { 3850 inline bool ComputedStyle::hasPseudoElementStyle() const {
3851 return m_nonInheritedData.m_pseudoBits & ElementPseudoIdMask; 3851 return m_nonInheritedData.m_pseudoBits & ElementPseudoIdMask;
3852 } 3852 }
3853 3853
3854 } // namespace blink 3854 } // namespace blink
3855 3855
3856 #endif // ComputedStyle_h 3856 #endif // ComputedStyle_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698