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

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

Issue 1024473004: Do not treat '0' as 'none' for font-size-adjust (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 9 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 371 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 return createFromColor(property, style); 382 return createFromColor(property, style);
383 case CSSPropertyFloodOpacity: 383 case CSSPropertyFloodOpacity:
384 return createFromDouble(style.floodOpacity()); 384 return createFromDouble(style.floodOpacity());
385 case CSSPropertyFontSize: 385 case CSSPropertyFontSize:
386 // Must pass a specified size to setFontSize if Text Autosizing is enabl ed, but a computed size 386 // Must pass a specified size to setFontSize if Text Autosizing is enabl ed, but a computed size
387 // if text zoom is enabled (if neither is enabled it's irrelevant as the y're probably the same). 387 // if text zoom is enabled (if neither is enabled it's irrelevant as the y're probably the same).
388 // FIXME: Should we introduce an option to pass the computed font size h ere, allowing consumers to 388 // FIXME: Should we introduce an option to pass the computed font size h ere, allowing consumers to
389 // enable text zoom rather than Text Autosizing? See http://crbug.com/22 7545. 389 // enable text zoom rather than Text Autosizing? See http://crbug.com/22 7545.
390 return createFromDouble(style.specifiedFontSize()); 390 return createFromDouble(style.specifiedFontSize());
391 case CSSPropertyFontSizeAdjust: 391 case CSSPropertyFontSizeAdjust:
392 return createFromDouble(style.fontSizeAdjust(), AnimatableDouble::Interp olationIsNonContinuousWithZero); 392 return style.hasFontSizeAdjust() ? createFromDouble(style.fontSizeAdjust ()) : AnimatableUnknown::create(CSSValueNone);
393 case CSSPropertyFontStretch: 393 case CSSPropertyFontStretch:
394 return createFromFontStretch(style.fontStretch()); 394 return createFromFontStretch(style.fontStretch());
395 case CSSPropertyFontWeight: 395 case CSSPropertyFontWeight:
396 return createFromFontWeight(style.fontWeight()); 396 return createFromFontWeight(style.fontWeight());
397 case CSSPropertyHeight: 397 case CSSPropertyHeight:
398 return createFromLength(style.height(), style); 398 return createFromLength(style.height(), style);
399 case CSSPropertyLightingColor: 399 case CSSPropertyLightingColor:
400 return createFromColor(property, style); 400 return createFromColor(property, style);
401 case CSSPropertyListStyleImage: 401 case CSSPropertyListStyleImage:
402 return createFromStyleImage(style.listStyleImage()); 402 return createFromStyleImage(style.listStyleImage());
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
556 case CSSPropertyZIndex: 556 case CSSPropertyZIndex:
557 return createFromDouble(style.zIndex()); 557 return createFromDouble(style.zIndex());
558 default: 558 default:
559 ASSERT_NOT_REACHED(); 559 ASSERT_NOT_REACHED();
560 // This return value is to avoid a release crash if possible. 560 // This return value is to avoid a release crash if possible.
561 return AnimatableUnknown::create(nullptr); 561 return AnimatableUnknown::create(nullptr);
562 } 562 }
563 } 563 }
564 564
565 } // namespace blink 565 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698