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

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

Issue 14907011: Support 'paint-order' from SVG2. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebased Created 7 years, 4 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 | « Source/core/css/CSSParser.h ('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 4709 matching lines...) Expand 10 before | Expand all | Expand 10 after
4720 case CSSValueNonScalingStroke: 4720 case CSSValueNonScalingStroke:
4721 return VE_NON_SCALING_STROKE; 4721 return VE_NON_SCALING_STROKE;
4722 default: 4722 default:
4723 break; 4723 break;
4724 } 4724 }
4725 4725
4726 ASSERT_NOT_REACHED(); 4726 ASSERT_NOT_REACHED();
4727 return VE_NONE; 4727 return VE_NONE;
4728 } 4728 }
4729 4729
4730 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(EPaintOrderType e)
4731 : CSSValue(PrimitiveClass)
4732 {
4733 m_primitiveUnitType = CSS_VALUE_ID;
4734 switch (e) {
4735 case PT_FILL:
4736 m_value.valueID = CSSValueFill;
4737 break;
4738 case PT_STROKE:
4739 m_value.valueID = CSSValueStroke;
4740 break;
4741 case PT_MARKERS:
4742 m_value.valueID = CSSValueMarkers;
4743 break;
4744 default:
4745 ASSERT_NOT_REACHED();
4746 m_value.valueID = CSSValueFill;
4747 break;
4748 }
4749 }
4750
4751 template<> inline CSSPrimitiveValue::operator EPaintOrderType() const
4752 {
4753 ASSERT(isValueID());
4754 switch (m_value.valueID) {
4755 case CSSValueFill:
4756 return PT_FILL;
4757 case CSSValueStroke:
4758 return PT_STROKE;
4759 case CSSValueMarkers:
4760 return PT_MARKERS;
4761 default:
4762 break;
4763 }
4764
4765 ASSERT_NOT_REACHED();
4766 return PT_NONE;
4767 }
4768
4730 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(EMaskType e) 4769 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(EMaskType e)
4731 : CSSValue(PrimitiveClass) 4770 : CSSValue(PrimitiveClass)
4732 { 4771 {
4733 m_primitiveUnitType = CSS_VALUE_ID; 4772 m_primitiveUnitType = CSS_VALUE_ID;
4734 switch (e) { 4773 switch (e) {
4735 case MT_LUMINANCE: 4774 case MT_LUMINANCE:
4736 m_value.valueID = CSSValueLuminance; 4775 m_value.valueID = CSSValueLuminance;
4737 break; 4776 break;
4738 case MT_ALPHA: 4777 case MT_ALPHA:
4739 m_value.valueID = CSSValueAlpha; 4778 m_value.valueID = CSSValueAlpha;
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
4783 break; 4822 break;
4784 } 4823 }
4785 4824
4786 ASSERT_NOT_REACHED(); 4825 ASSERT_NOT_REACHED();
4787 return TouchActionNone; 4826 return TouchActionNone;
4788 } 4827 }
4789 4828
4790 } 4829 }
4791 4830
4792 #endif 4831 #endif
OLDNEW
« no previous file with comments | « Source/core/css/CSSParser.h ('k') | Source/core/css/CSSProperty.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698