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

Side by Side Diff: Source/core/css/CSSSelector.h

Issue 1167523005: Remove mutable from members in CSSSelector. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: 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) 1999-2003 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999-2003 Lars Knoll (knoll@kde.org)
3 * 1999 Waldo Bastian (bastian@kde.org) 3 * 1999 Waldo Bastian (bastian@kde.org)
4 * Copyright (C) 2004, 2006, 2007, 2008, 2009, 2010, 2013 Apple Inc. All rights reserved. 4 * Copyright (C) 2004, 2006, 2007, 2008, 2009, 2010, 2013 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after
299 enum LinkMatchMask { MatchLink = 1, MatchVisited = 2, MatchAll = MatchLi nk | MatchVisited }; 299 enum LinkMatchMask { MatchLink = 1, MatchVisited = 2, MatchAll = MatchLi nk | MatchVisited };
300 unsigned computeLinkMatchType() const; 300 unsigned computeLinkMatchType() const;
301 301
302 bool isForPage() const { return m_isForPage; } 302 bool isForPage() const { return m_isForPage; }
303 void setForPage() { m_isForPage = true; } 303 void setForPage() { m_isForPage = true; }
304 304
305 bool relationIsAffectedByPseudoContent() const { return m_relationIsAffe ctedByPseudoContent; } 305 bool relationIsAffectedByPseudoContent() const { return m_relationIsAffe ctedByPseudoContent; }
306 void setRelationIsAffectedByPseudoContent() { m_relationIsAffectedByPseu doContent = true; } 306 void setRelationIsAffectedByPseudoContent() { m_relationIsAffectedByPseu doContent = true; }
307 307
308 private: 308 private:
309 unsigned m_relation : 3; // enum Relation 309 unsigned m_relation : 3; // enum Relation
310 mutable unsigned m_match : 4; // enum Match 310 unsigned m_match : 4; // enum Match
311 mutable unsigned m_pseudoType : 8; // PseudoType 311 unsigned m_pseudoType : 8; // enum PseudoType
312 unsigned m_isLastInSelectorList : 1; 312 unsigned m_isLastInSelectorList : 1;
313 unsigned m_isLastInTagHistory : 1; 313 unsigned m_isLastInTagHistory : 1;
314 unsigned m_hasRareData : 1; 314 unsigned m_hasRareData : 1;
315 unsigned m_isForPage : 1; 315 unsigned m_isForPage : 1;
316 unsigned m_tagIsImplicit : 1; 316 unsigned m_tagIsImplicit : 1;
317 unsigned m_relationIsAffectedByPseudoContent : 1; 317 unsigned m_relationIsAffectedByPseudoContent : 1;
318 318
319 void setPseudoType(PseudoType pseudoType) 319 void setPseudoType(PseudoType pseudoType)
320 { 320 {
321 m_pseudoType = pseudoType; 321 m_pseudoType = pseudoType;
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
480 if (m_hasRareData) 480 if (m_hasRareData)
481 return m_data.m_rareData->m_value; 481 return m_data.m_rareData->m_value;
482 // AtomicString is really just a StringImpl* so the cast below is safe. 482 // AtomicString is really just a StringImpl* so the cast below is safe.
483 // FIXME: Perhaps call sites could be changed to accept StringImpl? 483 // FIXME: Perhaps call sites could be changed to accept StringImpl?
484 return *reinterpret_cast<const AtomicString*>(&m_data.m_value); 484 return *reinterpret_cast<const AtomicString*>(&m_data.m_value);
485 } 485 }
486 486
487 } // namespace blink 487 } // namespace blink
488 488
489 #endif // CSSSelector_h 489 #endif // CSSSelector_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