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

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

Issue 14612004: Remove CURSOR_VISIBILITY, it's always off (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix UseCounter 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/css/CSSParser.cpp ('k') | Source/core/css/CSSProperty.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. (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 1133 matching lines...) Expand 10 before | Expand all | Expand 10 after
1144 1144
1145 template<> inline CSSPrimitiveValue::operator ECursor() const 1145 template<> inline CSSPrimitiveValue::operator ECursor() const
1146 { 1146 {
1147 if (m_value.ident == CSSValueCopy) 1147 if (m_value.ident == CSSValueCopy)
1148 return CURSOR_COPY; 1148 return CURSOR_COPY;
1149 if (m_value.ident == CSSValueNone) 1149 if (m_value.ident == CSSValueNone)
1150 return CURSOR_NONE; 1150 return CURSOR_NONE;
1151 return static_cast<ECursor>(m_value.ident - CSSValueAuto); 1151 return static_cast<ECursor>(m_value.ident - CSSValueAuto);
1152 } 1152 }
1153 1153
1154
1155 #if ENABLE(CURSOR_VISIBILITY)
1156 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(CursorVisibility e)
1157 : CSSValue(PrimitiveClass)
1158 {
1159 m_primitiveUnitType = CSS_IDENT;
1160 switch (e) {
1161 case CursorVisibilityAuto:
1162 m_value.ident = CSSValueAuto;
1163 break;
1164 case CursorVisibilityAutoHide:
1165 m_value.ident = CSSValueAutoHide;
1166 break;
1167 }
1168 }
1169
1170 template<> inline CSSPrimitiveValue::operator CursorVisibility() const
1171 {
1172 if (m_value.ident == CSSValueAuto)
1173 return CursorVisibilityAuto;
1174 if (m_value.ident == CSSValueAutoHide)
1175 return CursorVisibilityAutoHide;
1176
1177 ASSERT_NOT_REACHED();
1178 return CursorVisibilityAuto;
1179 }
1180 #endif
1181
1182 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(EDisplay e) 1154 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(EDisplay e)
1183 : CSSValue(PrimitiveClass) 1155 : CSSValue(PrimitiveClass)
1184 { 1156 {
1185 m_primitiveUnitType = CSS_IDENT; 1157 m_primitiveUnitType = CSS_IDENT;
1186 switch (e) { 1158 switch (e) {
1187 case INLINE: 1159 case INLINE:
1188 m_value.ident = CSSValueInline; 1160 m_value.ident = CSSValueInline;
1189 break; 1161 break;
1190 case BLOCK: 1162 case BLOCK:
1191 m_value.ident = CSSValueBlock; 1163 m_value.ident = CSSValueBlock;
(...skipping 3342 matching lines...) Expand 10 before | Expand all | Expand 10 after
4534 4506
4535 ASSERT_NOT_REACHED(); 4507 ASSERT_NOT_REACHED();
4536 return MT_LUMINANCE; 4508 return MT_LUMINANCE;
4537 } 4509 }
4538 4510
4539 #endif // ENABLE(SVG) 4511 #endif // ENABLE(SVG)
4540 4512
4541 } 4513 }
4542 4514
4543 #endif 4515 #endif
OLDNEW
« no previous file with comments | « Source/core/css/CSSParser.cpp ('k') | Source/core/css/CSSProperty.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698