Commit c4672c68 authored by ager@chromium.org's avatar ager@chromium.org

Fix oilpan compilation after css parser changes.

TBR=haraken@chromium.org, oilpan-reviews@chromium.org, wibling@chromium.org
NOTRY=true

Review URL: https://codereview.chromium.org/220763005

git-svn-id: svn://svn.chromium.org/blink/trunk@170556 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent e596caec
...@@ -3489,7 +3489,7 @@ bool CSSPropertyParser::parseGridTemplateRowsAndAreas(PassRefPtrWillBeRawPtr<CSS ...@@ -3489,7 +3489,7 @@ bool CSSPropertyParser::parseGridTemplateRowsAndAreas(PassRefPtrWillBeRawPtr<CSS
size_t rowCount = 0; size_t rowCount = 0;
size_t columnCount = 0; size_t columnCount = 0;
bool trailingIdentWasAdded = false; bool trailingIdentWasAdded = false;
RefPtr<CSSValueList> templateRows = CSSValueList::createSpaceSeparated(); RefPtrWillBeRawPtr<CSSValueList> templateRows = CSSValueList::createSpaceSeparated();
// At least template-areas strings must be defined. // At least template-areas strings must be defined.
if (!m_valueList->current()) if (!m_valueList->current())
...@@ -3513,7 +3513,7 @@ bool CSSPropertyParser::parseGridTemplateRowsAndAreas(PassRefPtrWillBeRawPtr<CSS ...@@ -3513,7 +3513,7 @@ bool CSSPropertyParser::parseGridTemplateRowsAndAreas(PassRefPtrWillBeRawPtr<CSS
// Handle template-rows's track-size. // Handle template-rows's track-size.
if (m_valueList->current() && m_valueList->current()->unit != CSSParserValue::ValueList && m_valueList->current()->unit != CSSPrimitiveValue::CSS_STRING) { if (m_valueList->current() && m_valueList->current()->unit != CSSParserValue::ValueList && m_valueList->current()->unit != CSSPrimitiveValue::CSS_STRING) {
RefPtr<CSSValue> value = parseGridTrackSize(*m_valueList); RefPtrWillBeRawPtr<CSSValue> value = parseGridTrackSize(*m_valueList);
if (!value) if (!value)
return false; return false;
templateRows->append(value); templateRows->append(value);
...@@ -3536,7 +3536,7 @@ bool CSSPropertyParser::parseGridTemplateRowsAndAreas(PassRefPtrWillBeRawPtr<CSS ...@@ -3536,7 +3536,7 @@ bool CSSPropertyParser::parseGridTemplateRowsAndAreas(PassRefPtrWillBeRawPtr<CSS
addProperty(CSSPropertyGridTemplateColumns, cssValuePool().createIdentifierValue(CSSValueNone), important); addProperty(CSSPropertyGridTemplateColumns, cssValuePool().createIdentifierValue(CSSValueNone), important);
// [<line-names>? <string> [<track-size> <line-names>]? ]+ // [<line-names>? <string> [<track-size> <line-names>]? ]+
RefPtr<CSSValue> templateAreas = CSSGridTemplateAreasValue::create(gridAreaMap, rowCount, columnCount); RefPtrWillBeRawPtr<CSSValue> templateAreas = CSSGridTemplateAreasValue::create(gridAreaMap, rowCount, columnCount);
addProperty(CSSPropertyGridTemplateAreas, templateAreas.release(), important); addProperty(CSSPropertyGridTemplateAreas, templateAreas.release(), important);
addProperty(CSSPropertyGridTemplateRows, templateRows.release(), important); addProperty(CSSPropertyGridTemplateRows, templateRows.release(), important);
...@@ -3567,14 +3567,19 @@ bool CSSPropertyParser::parseGridTemplateShorthand(bool important) ...@@ -3567,14 +3567,19 @@ bool CSSPropertyParser::parseGridTemplateShorthand(bool important)
} }
unsigned index = 0; unsigned index = 0;
RefPtr<CSSValue> columnsValue = firstValueIsNone ? cssValuePool().createIdentifierValue(CSSValueNone) : parseGridTrackList(important); RefPtrWillBeRawPtr<CSSValue> columnsValue = nullptr;
if (firstValueIsNone) {
columnsValue = cssValuePool().createIdentifierValue(CSSValueNone);
} else {
columnsValue = parseGridTrackList(important);
}
// 2- <grid-template-columns> / <grid-template-columns> syntax. // 2- <grid-template-columns> / <grid-template-columns> syntax.
if (columnsValue) { if (columnsValue) {
if (!(m_valueList->current() && isForwardSlashOperator(m_valueList->current()) && m_valueList->next())) if (!(m_valueList->current() && isForwardSlashOperator(m_valueList->current()) && m_valueList->next()))
return false; return false;
index = m_valueList->currentIndex(); index = m_valueList->currentIndex();
if (RefPtr<CSSValue> rowsValue = parseGridTrackList(important)) { if (RefPtrWillBeRawPtr<CSSValue> rowsValue = parseGridTrackList(important)) {
if (m_valueList->current()) if (m_valueList->current())
return false; return false;
addProperty(CSSPropertyGridTemplateColumns, columnsValue, important); addProperty(CSSPropertyGridTemplateColumns, columnsValue, important);
...@@ -3662,7 +3667,9 @@ void CSSPropertyParser::parseGridLineNames(CSSParserValueList& inputList, CSSVal ...@@ -3662,7 +3667,9 @@ void CSSPropertyParser::parseGridLineNames(CSSParserValueList& inputList, CSSVal
// Need to ensure the identList is at the heading index, since the parserList might have been rewound. // Need to ensure the identList is at the heading index, since the parserList might have been rewound.
identList->setCurrentIndex(0); identList->setCurrentIndex(0);
RefPtrWillBeRawPtr<CSSGridLineNamesValue> lineNames = previousNamedAreaTrailingLineNames ? previousNamedAreaTrailingLineNames : CSSGridLineNamesValue::create(); RefPtrWillBeRawPtr<CSSGridLineNamesValue> lineNames = previousNamedAreaTrailingLineNames;
if (!lineNames)
lineNames = CSSGridLineNamesValue::create();
while (CSSParserValue* identValue = identList->current()) { while (CSSParserValue* identValue = identList->current()) {
ASSERT(identValue->unit == CSSPrimitiveValue::CSS_IDENT); ASSERT(identValue->unit == CSSPrimitiveValue::CSS_IDENT);
RefPtrWillBeRawPtr<CSSPrimitiveValue> lineName = createPrimitiveStringValue(identValue); RefPtrWillBeRawPtr<CSSPrimitiveValue> lineName = createPrimitiveStringValue(identValue);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment