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

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

Issue 2882903002: Make EOverflowWrap an enum class. (Closed)
Patch Set: Rebase Created 3 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/LayoutTextControl.cpp » ('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. 4 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved.
5 * (http://www.torchmobile.com/) 5 * (http://www.torchmobile.com/)
6 * Copyright (C) 2009 Jeff Schiller <codedread@gmail.com> 6 * Copyright (C) 2009 Jeff Schiller <codedread@gmail.com>
7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
8 * 8 *
9 * Redistribution and use in source and binary forms, with or without 9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions 10 * modification, are permitted provided that the following conditions
(...skipping 1505 matching lines...) Expand 10 before | Expand all | Expand 10 after
1516 } 1516 }
1517 1517
1518 NOTREACHED(); 1518 NOTREACHED();
1519 return kNormalWordBreak; 1519 return kNormalWordBreak;
1520 } 1520 }
1521 1521
1522 template <> 1522 template <>
1523 inline CSSIdentifierValue::CSSIdentifierValue(EOverflowWrap e) 1523 inline CSSIdentifierValue::CSSIdentifierValue(EOverflowWrap e)
1524 : CSSValue(kIdentifierClass) { 1524 : CSSValue(kIdentifierClass) {
1525 switch (e) { 1525 switch (e) {
1526 case kNormalOverflowWrap: 1526 case EOverflowWrap::kNormal:
1527 value_id_ = CSSValueNormal; 1527 value_id_ = CSSValueNormal;
1528 break; 1528 break;
1529 case kBreakOverflowWrap: 1529 case EOverflowWrap::kBreakWord:
1530 value_id_ = CSSValueBreakWord; 1530 value_id_ = CSSValueBreakWord;
1531 break; 1531 break;
1532 } 1532 }
1533 } 1533 }
1534 1534
1535 template <> 1535 template <>
1536 inline EOverflowWrap CSSIdentifierValue::ConvertTo() const { 1536 inline EOverflowWrap CSSIdentifierValue::ConvertTo() const {
1537 switch (value_id_) { 1537 switch (value_id_) {
1538 case CSSValueBreakWord: 1538 case CSSValueBreakWord:
1539 return kBreakOverflowWrap; 1539 return EOverflowWrap::kBreakWord;
1540 case CSSValueNormal: 1540 case CSSValueNormal:
1541 return kNormalOverflowWrap; 1541 return EOverflowWrap::kNormal;
1542 default: 1542 default:
1543 break; 1543 break;
1544 } 1544 }
1545 1545
1546 NOTREACHED(); 1546 NOTREACHED();
1547 return kNormalOverflowWrap; 1547 return EOverflowWrap::kNormal;
1548 } 1548 }
1549 1549
1550 template <> 1550 template <>
1551 inline CSSIdentifierValue::CSSIdentifierValue(TextCombine e) 1551 inline CSSIdentifierValue::CSSIdentifierValue(TextCombine e)
1552 : CSSValue(kIdentifierClass) { 1552 : CSSValue(kIdentifierClass) {
1553 switch (e) { 1553 switch (e) {
1554 case kTextCombineNone: 1554 case kTextCombineNone:
1555 value_id_ = CSSValueNone; 1555 value_id_ = CSSValueNone;
1556 break; 1556 break;
1557 case kTextCombineAll: 1557 case kTextCombineAll:
(...skipping 1762 matching lines...) Expand 10 before | Expand all | Expand 10 after
3320 default: 3320 default:
3321 break; 3321 break;
3322 } 3322 }
3323 NOTREACHED(); 3323 NOTREACHED();
3324 return kContainsNone; 3324 return kContainsNone;
3325 } 3325 }
3326 3326
3327 } // namespace blink 3327 } // namespace blink
3328 3328
3329 #endif 3329 #endif
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/LayoutTextControl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698