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

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

Issue 40733004: Replace compile flag with runtime check for text-underline-position (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Julien's review #2 (rebased) Created 7 years, 1 month 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
« no previous file with comments | « Source/core/css/CSSParser-in.cpp ('k') | Source/core/css/CSSProperties.in » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 2479 matching lines...) Expand 10 before | Expand all | Expand 10 after
2490 case CSSValueWavy: 2490 case CSSValueWavy:
2491 return TextDecorationStyleWavy; 2491 return TextDecorationStyleWavy;
2492 default: 2492 default:
2493 break; 2493 break;
2494 } 2494 }
2495 2495
2496 ASSERT_NOT_REACHED(); 2496 ASSERT_NOT_REACHED();
2497 return TextDecorationStyleSolid; 2497 return TextDecorationStyleSolid;
2498 } 2498 }
2499 2499
2500 #if ENABLE(CSS3_TEXT)
2501 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(TextUnderlinePosition e) 2500 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(TextUnderlinePosition e)
2502 : CSSValue(PrimitiveClass) 2501 : CSSValue(PrimitiveClass)
2503 { 2502 {
2504 m_primitiveUnitType = CSS_VALUE_ID; 2503 m_primitiveUnitType = CSS_VALUE_ID;
2505 switch (e) { 2504 switch (e) {
2506 case TextUnderlinePositionAuto: 2505 case TextUnderlinePositionAuto:
2507 m_value.valueID = CSSValueAuto; 2506 m_value.valueID = CSSValueAuto;
2508 break; 2507 break;
2509 case TextUnderlinePositionAlphabetic: 2508 case TextUnderlinePositionAlphabetic:
2510 m_value.valueID = CSSValueAlphabetic; 2509 m_value.valueID = CSSValueAlphabetic;
(...skipping 18 matching lines...) Expand all
2529 return TextUnderlinePositionUnder; 2528 return TextUnderlinePositionUnder;
2530 default: 2529 default:
2531 break; 2530 break;
2532 } 2531 }
2533 2532
2534 // FIXME: Implement support for 'under left' and 'under right' values. 2533 // FIXME: Implement support for 'under left' and 'under right' values.
2535 2534
2536 ASSERT_NOT_REACHED(); 2535 ASSERT_NOT_REACHED();
2537 return TextUnderlinePositionAuto; 2536 return TextUnderlinePositionAuto;
2538 } 2537 }
2539 #endif // CSS3_TEXT
2540 2538
2541 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(ETextSecurity e) 2539 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(ETextSecurity e)
2542 : CSSValue(PrimitiveClass) 2540 : CSSValue(PrimitiveClass)
2543 { 2541 {
2544 m_primitiveUnitType = CSS_VALUE_ID; 2542 m_primitiveUnitType = CSS_VALUE_ID;
2545 switch (e) { 2543 switch (e) {
2546 case TSNONE: 2544 case TSNONE:
2547 m_value.valueID = CSSValueNone; 2545 m_value.valueID = CSSValueNone;
2548 break; 2546 break;
2549 case TSDISC: 2547 case TSDISC:
(...skipping 2410 matching lines...) Expand 10 before | Expand all | Expand 10 after
4960 break; 4958 break;
4961 } 4959 }
4962 4960
4963 ASSERT_NOT_REACHED(); 4961 ASSERT_NOT_REACHED();
4964 return TouchActionDelayNone; 4962 return TouchActionDelayNone;
4965 } 4963 }
4966 4964
4967 } 4965 }
4968 4966
4969 #endif 4967 #endif
OLDNEW
« no previous file with comments | « Source/core/css/CSSParser-in.cpp ('k') | Source/core/css/CSSProperties.in » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698