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

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

Issue 143323014: *** DO NOT LAND *** Attempt to understand Regions complexity Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 11 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/CSSGrammar.y ('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 1946 matching lines...) Expand 10 before | Expand all | Expand 10 after
1957 case CSSValueAlternate: 1957 case CSSValueAlternate:
1958 return MALTERNATE; 1958 return MALTERNATE;
1959 default: 1959 default:
1960 break; 1960 break;
1961 } 1961 }
1962 1962
1963 ASSERT_NOT_REACHED(); 1963 ASSERT_NOT_REACHED();
1964 return MNONE; 1964 return MNONE;
1965 } 1965 }
1966 1966
1967 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(RegionFragment e)
1968 : CSSValue(PrimitiveClass)
1969 {
1970 m_primitiveUnitType = CSS_VALUE_ID;
1971 switch (e) {
1972 case AutoRegionFragment:
1973 m_value.valueID = CSSValueAuto;
1974 break;
1975 case BreakRegionFragment:
1976 m_value.valueID = CSSValueBreak;
1977 break;
1978 }
1979 }
1980
1981 template<> inline CSSPrimitiveValue::operator RegionFragment() const
1982 {
1983 ASSERT(isValueID());
1984 switch (m_value.valueID) {
1985 case CSSValueAuto:
1986 return AutoRegionFragment;
1987 case CSSValueBreak:
1988 return BreakRegionFragment;
1989 default:
1990 break;
1991 }
1992
1993 ASSERT_NOT_REACHED();
1994 return AutoRegionFragment;
1995 }
1996
1997 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(EMarqueeDirection e) 1967 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(EMarqueeDirection e)
1998 : CSSValue(PrimitiveClass) 1968 : CSSValue(PrimitiveClass)
1999 { 1969 {
2000 m_primitiveUnitType = CSS_VALUE_ID; 1970 m_primitiveUnitType = CSS_VALUE_ID;
2001 switch (e) { 1971 switch (e) {
2002 case MFORWARD: 1972 case MFORWARD:
2003 m_value.valueID = CSSValueForwards; 1973 m_value.valueID = CSSValueForwards;
2004 break; 1974 break;
2005 case MBACKWARD: 1975 case MBACKWARD:
2006 m_value.valueID = CSSValueBackwards; 1976 m_value.valueID = CSSValueBackwards;
(...skipping 3033 matching lines...) Expand 10 before | Expand all | Expand 10 after
5040 default: 5010 default:
5041 break; 5011 break;
5042 } 5012 }
5043 ASSERT_NOT_REACHED(); 5013 ASSERT_NOT_REACHED();
5044 return OverflowAlignmentTrue; 5014 return OverflowAlignmentTrue;
5045 } 5015 }
5046 5016
5047 } 5017 }
5048 5018
5049 #endif 5019 #endif
OLDNEW
« no previous file with comments | « Source/core/css/CSSGrammar.y ('k') | Source/core/css/CSSProperties.in » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698