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

Side by Side Diff: Source/core/css/CSSPrimitiveValueMappings.h

Issue 14576017: Implement CSS3TextDecorations runtime flag in favor of CSS3_TEXT (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed a typo in css-properties-as-js-properties-expected-expected.txt Created 7 years, 7 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) 2007 Alexey Proskuryakov <ap@nypop.com>. 2 * Copyright (C) 2007 Alexey Proskuryakov <ap@nypop.com>.
3 * Copyright (C) 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. 3 * Copyright (C) 2008, 2009, 2010, 2011 Apple Inc. All rights reserved.
4 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 4 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
5 * Copyright (C) 2009 Jeff Schiller <codedread@gmail.com> 5 * Copyright (C) 2009 Jeff Schiller <codedread@gmail.com>
6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
7 * 7 *
8 * Redistribution and use in source and binary forms, with or without 8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions 9 * modification, are permitted provided that the following conditions
10 * are met: 10 * are met:
(...skipping 2286 matching lines...) Expand 10 before | Expand all | Expand 10 after
2297 case CSSValueLineThrough: 2297 case CSSValueLineThrough:
2298 return LINE_THROUGH; 2298 return LINE_THROUGH;
2299 case CSSValueBlink: 2299 case CSSValueBlink:
2300 return BLINK; 2300 return BLINK;
2301 } 2301 }
2302 2302
2303 ASSERT_NOT_REACHED(); 2303 ASSERT_NOT_REACHED();
2304 return TDNONE; 2304 return TDNONE;
2305 } 2305 }
2306 2306
2307 #if ENABLE(CSS3_TEXT)
2308 template<> inline CSSPrimitiveValue::operator TextDecorationStyle() const 2307 template<> inline CSSPrimitiveValue::operator TextDecorationStyle() const
2309 { 2308 {
2310 switch (m_value.ident) { 2309 switch (m_value.ident) {
2311 case CSSValueSolid: 2310 case CSSValueSolid:
2312 return TextDecorationStyleSolid; 2311 return TextDecorationStyleSolid;
2313 case CSSValueDouble: 2312 case CSSValueDouble:
2314 return TextDecorationStyleDouble; 2313 return TextDecorationStyleDouble;
2315 case CSSValueDotted: 2314 case CSSValueDotted:
2316 return TextDecorationStyleDotted; 2315 return TextDecorationStyleDotted;
2317 case CSSValueDashed: 2316 case CSSValueDashed:
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
2352 return TextUnderlinePositionAlphabetic; 2351 return TextUnderlinePositionAlphabetic;
2353 case CSSValueUnder: 2352 case CSSValueUnder:
2354 return TextUnderlinePositionUnder; 2353 return TextUnderlinePositionUnder;
2355 } 2354 }
2356 2355
2357 // FIXME: Implement support for 'under left' and 'under right' values. 2356 // FIXME: Implement support for 'under left' and 'under right' values.
2358 2357
2359 ASSERT_NOT_REACHED(); 2358 ASSERT_NOT_REACHED();
2360 return TextUnderlinePositionAuto; 2359 return TextUnderlinePositionAuto;
2361 } 2360 }
2362 #endif // CSS3_TEXT
2363 2361
2364 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(ETextSecurity e) 2362 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(ETextSecurity e)
2365 : CSSValue(PrimitiveClass) 2363 : CSSValue(PrimitiveClass)
2366 { 2364 {
2367 m_primitiveUnitType = CSS_IDENT; 2365 m_primitiveUnitType = CSS_IDENT;
2368 switch (e) { 2366 switch (e) {
2369 case TSNONE: 2367 case TSNONE:
2370 m_value.ident = CSSValueNone; 2368 m_value.ident = CSSValueNone;
2371 break; 2369 break;
2372 case TSDISC: 2370 case TSDISC:
(...skipping 2130 matching lines...) Expand 10 before | Expand all | Expand 10 after
4503 4501
4504 ASSERT_NOT_REACHED(); 4502 ASSERT_NOT_REACHED();
4505 return MT_LUMINANCE; 4503 return MT_LUMINANCE;
4506 } 4504 }
4507 4505
4508 #endif // ENABLE(SVG) 4506 #endif // ENABLE(SVG)
4509 4507
4510 } 4508 }
4511 4509
4512 #endif 4510 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698