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

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

Issue 2666483002: Changed ETableLayout to an enum class and renamed its members (Closed)
Patch Set: Use CSS keywords Created 3 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/style/ComputedStyle.h » ('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 2093 matching lines...) Expand 10 before | Expand all | Expand 10 after
2104 } 2104 }
2105 2105
2106 ASSERT_NOT_REACHED(); 2106 ASSERT_NOT_REACHED();
2107 return RESIZE_NONE; 2107 return RESIZE_NONE;
2108 } 2108 }
2109 2109
2110 template <> 2110 template <>
2111 inline CSSIdentifierValue::CSSIdentifierValue(ETableLayout e) 2111 inline CSSIdentifierValue::CSSIdentifierValue(ETableLayout e)
2112 : CSSValue(IdentifierClass) { 2112 : CSSValue(IdentifierClass) {
2113 switch (e) { 2113 switch (e) {
2114 case TableLayoutAuto: 2114 case ETableLayout::kAuto:
2115 m_valueID = CSSValueAuto; 2115 m_valueID = CSSValueAuto;
2116 break; 2116 break;
2117 case TableLayoutFixed: 2117 case ETableLayout::kFixed:
2118 m_valueID = CSSValueFixed; 2118 m_valueID = CSSValueFixed;
2119 break; 2119 break;
2120 } 2120 }
2121 } 2121 }
2122 2122
2123 template <> 2123 template <>
2124 inline ETableLayout CSSIdentifierValue::convertTo() const { 2124 inline ETableLayout CSSIdentifierValue::convertTo() const {
2125 switch (m_valueID) { 2125 switch (m_valueID) {
2126 case CSSValueFixed: 2126 case CSSValueFixed:
2127 return TableLayoutFixed; 2127 return ETableLayout::kFixed;
2128 case CSSValueAuto: 2128 case CSSValueAuto:
2129 return TableLayoutAuto; 2129 return ETableLayout::kAuto;
2130 default: 2130 default:
2131 break; 2131 break;
2132 } 2132 }
2133 2133
2134 ASSERT_NOT_REACHED(); 2134 ASSERT_NOT_REACHED();
2135 return TableLayoutAuto; 2135 return ETableLayout::kAuto;
2136 } 2136 }
2137 2137
2138 template <> 2138 template <>
2139 inline CSSIdentifierValue::CSSIdentifierValue(ETextAlign e) 2139 inline CSSIdentifierValue::CSSIdentifierValue(ETextAlign e)
2140 : CSSValue(IdentifierClass) { 2140 : CSSValue(IdentifierClass) {
2141 switch (e) { 2141 switch (e) {
2142 case ETextAlign::kStart: 2142 case ETextAlign::kStart:
2143 m_valueID = CSSValueStart; 2143 m_valueID = CSSValueStart;
2144 break; 2144 break;
2145 case ETextAlign::kEnd: 2145 case ETextAlign::kEnd:
(...skipping 2644 matching lines...) Expand 10 before | Expand all | Expand 10 after
4790 default: 4790 default:
4791 break; 4791 break;
4792 } 4792 }
4793 ASSERT_NOT_REACHED(); 4793 ASSERT_NOT_REACHED();
4794 return ContainsNone; 4794 return ContainsNone;
4795 } 4795 }
4796 4796
4797 } // namespace blink 4797 } // namespace blink
4798 4798
4799 #endif 4799 #endif
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/style/ComputedStyle.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698