| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "core/css/properties/CSSPropertyAPITransform.h" | 5 #include "core/css/properties/CSSPropertyTransformUtils.h" |
| 6 | 6 |
| 7 #include "core/css/CSSFunctionValue.h" | 7 #include "core/css/CSSFunctionValue.h" |
| 8 #include "core/css/CSSValueList.h" | 8 #include "core/css/CSSValueList.h" |
| 9 #include "core/css/parser/CSSParserContext.h" | 9 #include "core/css/parser/CSSParserContext.h" |
| 10 #include "core/css/parser/CSSParserLocalContext.h" | 10 #include "core/css/parser/CSSParserLocalContext.h" |
| 11 #include "core/css/parser/CSSPropertyParserHelpers.h" | 11 #include "core/css/parser/CSSPropertyParserHelpers.h" |
| 12 #include "platform/Length.h" | 12 #include "platform/Length.h" |
| 13 | 13 |
| 14 namespace blink { | 14 namespace blink { |
| 15 | 15 |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 181 } | 181 } |
| 182 if (parsed_value) | 182 if (parsed_value) |
| 183 transform_value->Append(*parsed_value); | 183 transform_value->Append(*parsed_value); |
| 184 if (!args.AtEnd()) | 184 if (!args.AtEnd()) |
| 185 return nullptr; | 185 return nullptr; |
| 186 return transform_value; | 186 return transform_value; |
| 187 } | 187 } |
| 188 | 188 |
| 189 } // namespace | 189 } // namespace |
| 190 | 190 |
| 191 const CSSValue* CSSPropertyAPITransform::parseSingleValue( | 191 CSSValue* CSSPropertyTransformUtils::ConsumeTransformList( |
| 192 CSSParserTokenRange& range, | 192 CSSParserTokenRange& range, |
| 193 const CSSParserContext& context, | 193 const CSSParserContext& context, |
| 194 const CSSParserLocalContext& local_context) { | 194 const CSSParserLocalContext& local_context) { |
| 195 if (range.Peek().Id() == CSSValueNone) | 195 if (range.Peek().Id() == CSSValueNone) |
| 196 return CSSPropertyParserHelpers::ConsumeIdent(range); | 196 return CSSPropertyParserHelpers::ConsumeIdent(range); |
| 197 | 197 |
| 198 CSSValueList* list = CSSValueList::CreateSpaceSeparated(); | 198 CSSValueList* list = CSSValueList::CreateSpaceSeparated(); |
| 199 do { | 199 do { |
| 200 CSSValue* parsed_transform_value = | 200 CSSValue* parsed_transform_value = |
| 201 ConsumeTransformValue(range, &context, local_context.UseAliasParsing()); | 201 ConsumeTransformValue(range, &context, local_context.UseAliasParsing()); |
| 202 if (!parsed_transform_value) | 202 if (!parsed_transform_value) |
| 203 return nullptr; | 203 return nullptr; |
| 204 list->Append(*parsed_transform_value); | 204 list->Append(*parsed_transform_value); |
| 205 } while (!range.AtEnd()); | 205 } while (!range.AtEnd()); |
| 206 | 206 |
| 207 return list; | 207 return list; |
| 208 } | 208 } |
| 209 | 209 |
| 210 } // namespace blink | 210 } // namespace blink |
| OLD | NEW |