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

Side by Side Diff: sky/engine/core/css/resolver/StyleBuilderCustom.cpp

Issue 689743002: First past at removing writing mode. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
4 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) 4 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com)
5 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) 5 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com)
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights reserved. 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights reserved.
7 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> 7 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org>
8 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> 8 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org>
9 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 9 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
10 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. 10 * Copyright (c) 2011, Code Aurora Forum. All rights reserved.
(...skipping 1017 matching lines...) Expand 10 before | Expand all | Expand 10 after
1028 return; 1028 return;
1029 } 1029 }
1030 1030
1031 if (!primitiveValue->isLength()) 1031 if (!primitiveValue->isLength())
1032 return; 1032 return;
1033 float perspectiveValue = primitiveValue->computeLength<float>(state.cssToLen gthConversionData()); 1033 float perspectiveValue = primitiveValue->computeLength<float>(state.cssToLen gthConversionData());
1034 if (perspectiveValue >= 0.0f) 1034 if (perspectiveValue >= 0.0f)
1035 state.style()->setPerspective(perspectiveValue); 1035 state.style()->setPerspective(perspectiveValue);
1036 } 1036 }
1037 1037
1038 void StyleBuilderFunctions::applyValueCSSPropertyWebkitWritingMode(StyleResolver State& state, CSSValue* value)
1039 {
1040 if (value->isPrimitiveValue())
1041 state.setWritingMode(*toCSSPrimitiveValue(value));
1042
1043 // FIXME: It is not ok to modify document state while applying style.
1044 if (state.element() && state.element() == state.document().documentElement() )
1045 state.document().setWritingModeSetOnDocumentElement(true);
1046 }
1047
1048 void StyleBuilderFunctions::applyValueCSSPropertyWebkitTextOrientation(StyleReso lverState& state, CSSValue* value) 1038 void StyleBuilderFunctions::applyValueCSSPropertyWebkitTextOrientation(StyleReso lverState& state, CSSValue* value)
1049 { 1039 {
1050 if (value->isPrimitiveValue()) 1040 if (value->isPrimitiveValue())
1051 state.setTextOrientation(*toCSSPrimitiveValue(value)); 1041 state.setTextOrientation(*toCSSPrimitiveValue(value));
1052 } 1042 }
1053 1043
1054 void StyleBuilderFunctions::applyValueCSSPropertyGridAutoFlow(StyleResolverState & state, CSSValue* value) 1044 void StyleBuilderFunctions::applyValueCSSPropertyGridAutoFlow(StyleResolverState & state, CSSValue* value)
1055 { 1045 {
1056 ASSERT(value->isValueList()); 1046 ASSERT(value->isValueList());
1057 CSSValueList* list = toCSSValueList(value); 1047 CSSValueList* list = toCSSValueList(value);
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
1101 break; 1091 break;
1102 default: 1092 default:
1103 ASSERT_NOT_REACHED(); 1093 ASSERT_NOT_REACHED();
1104 break; 1094 break;
1105 } 1095 }
1106 1096
1107 state.style()->setGridAutoFlow(autoFlow); 1097 state.style()->setGridAutoFlow(autoFlow);
1108 } 1098 }
1109 1099
1110 } // namespace blink 1100 } // namespace blink
OLDNEW
« no previous file with comments | « sky/engine/core/css/resolver/MatchedPropertiesCache.cpp ('k') | sky/engine/core/css/resolver/StyleResolver.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698