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

Side by Side Diff: Source/core/css/parser/CSSParserValues.h

Issue 1306823004: Split out String, URI and CustomIdent from CSSPrimitiveValue (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@split_out_attr_values
Patch Set: Rebase Created 5 years, 3 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) 2003 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2004, 2005, 2006, 2008, 2009, 2010 Apple Inc. All rights reserv ed. 3 * Copyright (C) 2004, 2005, 2006, 2008, 2009, 2010 Apple Inc. All rights reserv ed.
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 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 Operator = 0x100000, 57 Operator = 0x100000,
58 Function = 0x100001, 58 Function = 0x100001,
59 CalcFunction = 0x100002, 59 CalcFunction = 0x100002,
60 ValueList = 0x100003, 60 ValueList = 0x100003,
61 HexColor = 0x100004, 61 HexColor = 0x100004,
62 Identifier = 0x100005, 62 Identifier = 0x100005,
63 // Represents a dimension by a list of two values, a UnitType::Number an d an Identifier 63 // Represents a dimension by a list of two values, a UnitType::Number an d an Identifier
64 DimensionList = 0x100006, 64 DimensionList = 0x100006,
65 // Represents a unicode range by a pair of UChar32 values 65 // Represents a unicode range by a pair of UChar32 values
66 UnicodeRange = 0x100007, 66 UnicodeRange = 0x100007,
67 URI = 0x100008,
68 String = 0x100009,
67 }; 69 };
68 int m_unit; 70 int m_unit;
69 CSSPrimitiveValue::UnitType unit() const { return static_cast<CSSPrimitiveVa lue::UnitType>(m_unit); } 71 CSSPrimitiveValue::UnitType unit() const { return static_cast<CSSPrimitiveVa lue::UnitType>(m_unit); }
70 void setUnit(CSSPrimitiveValue::UnitType unit) { m_unit = static_cast<int>(u nit); } 72 void setUnit(CSSPrimitiveValue::UnitType unit) { m_unit = static_cast<int>(u nit); }
71 73
72 inline void setFromNumber(double value, CSSPrimitiveValue::UnitType); 74 inline void setFromNumber(double value, CSSPrimitiveValue::UnitType);
73 inline void setFromOperator(UChar); 75 inline void setFromOperator(UChar);
74 inline void setFromValueList(PassOwnPtr<CSSParserValueList>); 76 inline void setFromValueList(PassOwnPtr<CSSParserValueList>);
75 }; 77 };
76 78
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 { 206 {
205 id = CSSValueInvalid; 207 id = CSSValueInvalid;
206 this->valueList = valueList.leakPtr(); 208 this->valueList = valueList.leakPtr();
207 m_unit = ValueList; 209 m_unit = ValueList;
208 isInt = false; 210 isInt = false;
209 } 211 }
210 212
211 } 213 }
212 214
213 #endif 215 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698