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

Side by Side Diff: sky/engine/core/css/resolver/CSSToStyleMap.cpp

Issue 893093002: Delete remaining masks dead code. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 10 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) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com)
4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com)
5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All r ights reserved. 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All r ights reserved.
6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> 6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org>
7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> 7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org>
8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. 9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved.
10 * Copyright (C) Research In Motion Limited 2011. All rights reserved. 10 * Copyright (C) Research In Motion Limited 2011. All rights reserved.
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 if (pair) 249 if (pair)
250 primitiveValue = pair->second(); 250 primitiveValue = pair->second();
251 251
252 Length length = primitiveValue->convertToLength<FixedConversion | PercentCon version>(cssToLengthConversionData()); 252 Length length = primitiveValue->convertToLength<FixedConversion | PercentCon version>(cssToLengthConversionData());
253 253
254 layer->setYPosition(length); 254 layer->setYPosition(length);
255 if (pair) 255 if (pair)
256 layer->setBackgroundYOrigin(*(pair->first())); 256 layer->setBackgroundYOrigin(*(pair->first()));
257 } 257 }
258 258
259 void CSSToStyleMap::mapFillMaskSourceType(FillLayer* layer, CSSValue* value) con st
260 {
261 EMaskSourceType type = FillLayer::initialFillMaskSourceType(layer->type());
262 if (value->isInitialValue()) {
263 layer->setMaskSourceType(type);
264 return;
265 }
266
267 if (!value->isPrimitiveValue())
268 return;
269
270 switch (toCSSPrimitiveValue(value)->getValueID()) {
271 case CSSValueAlpha:
272 type = MaskAlpha;
273 break;
274 case CSSValueLuminance:
275 type = MaskLuminance;
276 break;
277 case CSSValueAuto:
278 break;
279 default:
280 ASSERT_NOT_REACHED();
281 }
282
283 layer->setMaskSourceType(type);
284 }
285
286 double CSSToStyleMap::mapAnimationDelay(CSSValue* value) 259 double CSSToStyleMap::mapAnimationDelay(CSSValue* value)
287 { 260 {
288 if (value->isInitialValue()) 261 if (value->isInitialValue())
289 return CSSTimingData::initialDelay(); 262 return CSSTimingData::initialDelay();
290 return toCSSPrimitiveValue(value)->computeSeconds(); 263 return toCSSPrimitiveValue(value)->computeSeconds();
291 } 264 }
292 265
293 Timing::PlaybackDirection CSSToStyleMap::mapAnimationDirection(CSSValue* value) 266 Timing::PlaybackDirection CSSToStyleMap::mapAnimationDirection(CSSValue* value)
294 { 267 {
295 if (value->isInitialValue()) 268 if (value->isInitialValue())
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
588 verticalRule = SpaceImageRule; 561 verticalRule = SpaceImageRule;
589 break; 562 break;
590 default: // CSSValueRepeat 563 default: // CSSValueRepeat
591 verticalRule = RepeatImageRule; 564 verticalRule = RepeatImageRule;
592 break; 565 break;
593 } 566 }
594 image.setVerticalRule(verticalRule); 567 image.setVerticalRule(verticalRule);
595 } 568 }
596 569
597 }; 570 };
OLDNEW
« no previous file with comments | « sky/engine/core/css/resolver/CSSToStyleMap.h ('k') | sky/engine/core/css/resolver/StyleAdjuster.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698