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

Side by Side Diff: Source/core/animation/css/CSSAnimatableValueFactory.cpp

Issue 26292004: Web Animations CSS: Support animation of stroke-dasharray property (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 7 years, 2 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 25 matching lines...) Expand all
36 #include "core/animation/AnimatableColor.h" 36 #include "core/animation/AnimatableColor.h"
37 #include "core/animation/AnimatableDouble.h" 37 #include "core/animation/AnimatableDouble.h"
38 #include "core/animation/AnimatableImage.h" 38 #include "core/animation/AnimatableImage.h"
39 #include "core/animation/AnimatableLength.h" 39 #include "core/animation/AnimatableLength.h"
40 #include "core/animation/AnimatableLengthBox.h" 40 #include "core/animation/AnimatableLengthBox.h"
41 #include "core/animation/AnimatableLengthSize.h" 41 #include "core/animation/AnimatableLengthSize.h"
42 #include "core/animation/AnimatableRepeatable.h" 42 #include "core/animation/AnimatableRepeatable.h"
43 #include "core/animation/AnimatableSVGLength.h" 43 #include "core/animation/AnimatableSVGLength.h"
44 #include "core/animation/AnimatableSVGPaint.h" 44 #include "core/animation/AnimatableSVGPaint.h"
45 #include "core/animation/AnimatableShapeValue.h" 45 #include "core/animation/AnimatableShapeValue.h"
46 #include "core/animation/AnimatableStrokeDasharrayList.h"
46 #include "core/animation/AnimatableTransform.h" 47 #include "core/animation/AnimatableTransform.h"
47 #include "core/animation/AnimatableUnknown.h" 48 #include "core/animation/AnimatableUnknown.h"
48 #include "core/animation/AnimatableVisibility.h" 49 #include "core/animation/AnimatableVisibility.h"
49 #include "core/animation/css/CSSAnimations.h" 50 #include "core/animation/css/CSSAnimations.h"
50 #include "core/css/CSSPrimitiveValue.h" 51 #include "core/css/CSSPrimitiveValue.h"
51 #include "core/platform/Length.h" 52 #include "core/platform/Length.h"
52 #include "core/platform/LengthBox.h" 53 #include "core/platform/LengthBox.h"
53 #include "core/rendering/style/RenderStyle.h" 54 #include "core/rendering/style/RenderStyle.h"
54 55
55 namespace WebCore { 56 namespace WebCore {
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 case CSSPropertyPaddingRight: 264 case CSSPropertyPaddingRight:
264 return createFromLength(style->paddingRight(), style); 265 return createFromLength(style->paddingRight(), style);
265 case CSSPropertyPaddingTop: 266 case CSSPropertyPaddingTop:
266 return createFromLength(style->paddingTop(), style); 267 return createFromLength(style->paddingTop(), style);
267 case CSSPropertyRight: 268 case CSSPropertyRight:
268 return createFromLength(style->right(), style); 269 return createFromLength(style->right(), style);
269 case CSSPropertyStrokeWidth: 270 case CSSPropertyStrokeWidth:
270 return AnimatableSVGLength::create(style->strokeWidth()); 271 return AnimatableSVGLength::create(style->strokeWidth());
271 case CSSPropertyStopOpacity: 272 case CSSPropertyStopOpacity:
272 return createFromDouble(style->stopOpacity()); 273 return createFromDouble(style->stopOpacity());
274 case CSSPropertyStrokeDasharray:
275 return AnimatableStrokeDasharrayList::create(style->strokeDashArray());
273 case CSSPropertyStrokeDashoffset: 276 case CSSPropertyStrokeDashoffset:
274 return AnimatableSVGLength::create(style->strokeDashOffset()); 277 return AnimatableSVGLength::create(style->strokeDashOffset());
275 case CSSPropertyStrokeMiterlimit: 278 case CSSPropertyStrokeMiterlimit:
276 return createFromDouble(style->strokeMiterLimit()); 279 return createFromDouble(style->strokeMiterLimit());
277 case CSSPropertyStrokeOpacity: 280 case CSSPropertyStrokeOpacity:
278 return createFromDouble(style->strokeOpacity()); 281 return createFromDouble(style->strokeOpacity());
279 case CSSPropertyStroke: 282 case CSSPropertyStroke:
280 return AnimatableSVGPaint::create(style->svgStyle()->strokePaintType(), style->svgStyle()->strokePaintColor(), style->svgStyle()->strokePaintUri()); 283 return AnimatableSVGPaint::create(style->svgStyle()->strokePaintType(), style->svgStyle()->strokePaintColor(), style->svgStyle()->strokePaintUri());
281 case CSSPropertyTextDecorationColor: 284 case CSSPropertyTextDecorationColor:
282 return createFromColor(property, style); 285 return createFromColor(property, style);
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
337 case CSSPropertyZoom: 340 case CSSPropertyZoom:
338 return createFromDouble(style->zoom()); 341 return createFromDouble(style->zoom());
339 default: 342 default:
340 RELEASE_ASSERT_WITH_MESSAGE(!CSSAnimations::isAnimatableProperty(propert y), "Web Animations not yet implemented: Create AnimatableValue from render styl e: %s", getPropertyNameString(property).utf8().data()); 343 RELEASE_ASSERT_WITH_MESSAGE(!CSSAnimations::isAnimatableProperty(propert y), "Web Animations not yet implemented: Create AnimatableValue from render styl e: %s", getPropertyNameString(property).utf8().data());
341 ASSERT_NOT_REACHED(); 344 ASSERT_NOT_REACHED();
342 return 0; 345 return 0;
343 } 346 }
344 } 347 }
345 348
346 } // namespace WebCore 349 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698