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

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

Issue 26340006: Web Animations: Support animation of flood-opacity (Closed) Base URL: https://chromium.googlesource.com/chromium/blink@master
Patch Set: Rebase 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
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 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 case CSSPropertyFill: 217 case CSSPropertyFill:
218 return AnimatableSVGPaint::create(style->svgStyle()->fillPaintType(), st yle->svgStyle()->fillPaintColor(), style->svgStyle()->fillPaintUri()); 218 return AnimatableSVGPaint::create(style->svgStyle()->fillPaintType(), st yle->svgStyle()->fillPaintColor(), style->svgStyle()->fillPaintUri());
219 case CSSPropertyFlexGrow: 219 case CSSPropertyFlexGrow:
220 return createFromDouble(style->flexGrow(), AnimatableDouble::Interpolati onIsNonContinuousWithZero); 220 return createFromDouble(style->flexGrow(), AnimatableDouble::Interpolati onIsNonContinuousWithZero);
221 case CSSPropertyFlexShrink: 221 case CSSPropertyFlexShrink:
222 return createFromDouble(style->flexShrink(), AnimatableDouble::Interpola tionIsNonContinuousWithZero); 222 return createFromDouble(style->flexShrink(), AnimatableDouble::Interpola tionIsNonContinuousWithZero);
223 case CSSPropertyFlexBasis: 223 case CSSPropertyFlexBasis:
224 return createFromLength(style->flexBasis(), style); 224 return createFromLength(style->flexBasis(), style);
225 case CSSPropertyFloodColor: 225 case CSSPropertyFloodColor:
226 return createFromColor(property, style); 226 return createFromColor(property, style);
227 case CSSPropertyFloodOpacity:
228 return createFromDouble(style->floodOpacity());
227 case CSSPropertyFontSize: 229 case CSSPropertyFontSize:
228 // Must pass a specified size to setFontSize if Text Autosizing is enabl ed, but a computed size 230 // Must pass a specified size to setFontSize if Text Autosizing is enabl ed, but a computed size
229 // if text zoom is enabled (if neither is enabled it's irrelevant as the y're probably the same). 231 // if text zoom is enabled (if neither is enabled it's irrelevant as the y're probably the same).
230 // FIXME: Should we introduce an option to pass the computed font size h ere, allowing consumers to 232 // FIXME: Should we introduce an option to pass the computed font size h ere, allowing consumers to
231 // enable text zoom rather than Text Autosizing? See http://crbug.com/22 7545. 233 // enable text zoom rather than Text Autosizing? See http://crbug.com/22 7545.
232 return createFromDouble(style->specifiedFontSize()); 234 return createFromDouble(style->specifiedFontSize());
233 case CSSPropertyHeight: 235 case CSSPropertyHeight:
234 return createFromLength(style->height(), style); 236 return createFromLength(style->height(), style);
235 case CSSPropertyKerning: 237 case CSSPropertyKerning:
236 return AnimatableSVGLength::create(style->kerning()); 238 return AnimatableSVGLength::create(style->kerning());
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 case CSSPropertyZoom: 355 case CSSPropertyZoom:
354 return createFromDouble(style->zoom()); 356 return createFromDouble(style->zoom());
355 default: 357 default:
356 RELEASE_ASSERT_WITH_MESSAGE(!CSSAnimations::isAnimatableProperty(propert y), "Web Animations not yet implemented: Create AnimatableValue from render styl e: %s", getPropertyNameString(property).utf8().data()); 358 RELEASE_ASSERT_WITH_MESSAGE(!CSSAnimations::isAnimatableProperty(propert y), "Web Animations not yet implemented: Create AnimatableValue from render styl e: %s", getPropertyNameString(property).utf8().data());
357 ASSERT_NOT_REACHED(); 359 ASSERT_NOT_REACHED();
358 return 0; 360 return 0;
359 } 361 }
360 } 362 }
361 363
362 } // namespace WebCore 364 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698