diff options
| author | vasilii <vasilii@chromium.org> | 2016-03-11 03:08:33 -0800 |
|---|---|---|
| committer | Commit bot <commit-bot@chromium.org> | 2016-03-11 11:09:33 +0000 |
| commit | 2b4847f559905c9209427913190b72848096a873 (patch) | |
| tree | 65fef8c3ee7b4353382dc4bd476b97b5a5eaf952 | |
| parent | 5778d3531acbd4019a491e9f20fa0785c1d607a8 (diff) | |
| download | chromium_src-2b4847f559905c9209427913190b72848096a873.zip chromium_src-2b4847f559905c9209427913190b72848096a873.tar.gz chromium_src-2b4847f559905c9209427913190b72848096a873.tar.bz2 | |
Revert of [css-grid] Store auto-repeat data in ComputedStyle (patchset #5 id:80001 of https://codereview.chromium.org/1731233002/ )
Reason for revert:
Broke compilation on "WebKit Linux non-Oilpan Builder" (https://build.chromium.org/p/chromium.webkit/builders/WebKit%20Linux%20non-Oilpan%20Builder/builds/2263/steps/compile/logs/stdio)
FAILED: /b/build/goma/gomacc ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF obj/third_party/WebKit/Source/core/remaining/StyleBuilderConverter.o.d -DV8_DEPRECATION_WARNINGS -DCLD_VERSION=2 -DENABLE_MDNS=1 -DENABLE_NOTIFICATIONS -DENABLE_PEPPER_CDMS -DENABLE_PLUGINS=1 -DENABLE_PDF=1 -DENABLE_PRINTING=1 -DENABLE_BASIC_PRINTING=1 -DENABLE_PRINT_PREVIEW=1 -DENABLE_SPELLCHECK=1 -DUSE_UDEV -DUI_COMPOSITOR_IMAGE_TRANSPORT -DUSE_AURA=1 -DUSE_PANGO=1 -DUSE_CAIRO=1 -DUSE_CLIPBOARD_AURAX11=1 -DUSE_DEFAULT_RENDER_THEME=1 -DUSE_GLIB=1 -DUSE_OPENSSL=1 -DUSE_NSS_CERTS=1 -DUSE_X11=1 -DENABLE_WEBRTC=1 -DENABLE_EXTENSIONS=1 -DENABLE_CONFIGURATION_POLICY -DENABLE_TASK_MANAGER=1 -DENABLE_THEMES=1 -DENABLE_CAPTIVE_PORTAL_DETECTION=1 -DENABLE_SESSION_SERVICE=1 -DENABLE_APP_LIST=1 -DENABLE_SETTINGS_APP=1 -DENABLE_SUPERVISED_USERS=1 -DENABLE_SERVICE_DISCOVERY=1 -DENABLE_AUTOFILL_DIALOG=1 -DENABLE_TOPCHROME_MD=1 -DFULL_SAFE_BROWSING -DSAFE_BROWSING_CSD -DSAFE_BROWSING_DB_LOCAL -DCHROMIUM_BUILD -DENABLE_MEDIA_ROUTER=1 -DFIELDTRIAL_TESTING_ENABLED -DCR_CLANG_REVISION=262839-1 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -DBLINK_CORE_IMPLEMENTATION=1 -DGL_GLEXT_PROTOTYPES -DBLINK_IMPLEMENTATION=1 -DINSIDE_BLINK -DSK_IGNORE_LINEONLY_AA_CONVEX_PATH_OPTS -DSK_SUPPORT_GPU=1 -DENABLE_LAYOUT_UNIT_IN_INLINE_BOXES=0 -DWTF_USE_CONCATENATED_IMPULSE_RESPONSES=1 -DENABLE_INPUT_MULTIPLE_FIELDS_UI=1 -DWTF_USE_ICCJPEG=1 -DWTF_USE_QCMSLIB=1 -DWTF_USE_WEBAUDIO_FFMPEG=1 -DWTF_USE_DEFAULT_RENDER_THEME=1 -DU_USING_ICU_NAMESPACE=0 -DU_ENABLE_DYLOAD=0 -DU_STATIC_IMPLEMENTATION -DCHROME_PNG_WRITE_SUPPORT -DPNG_USER_CONFIG -DLIBXSLT_STATIC -I../.. -Igen -I../../third_party/khronos -I../../gpu -I../../build/linux/debian_wheezy_amd64-sysroot/usr/include/glib-2.0 -I../../build/linux/debian_wheezy_amd64-sysroot/usr/lib/x86_64-linux-gnu/glib-2.0/include -I../../third_party/libwebp -I../../third_party/WebKit/Source -Igen/blink -I../../third_party/WebKit/Source -I../../third_party/WebKit -Igen/blink -I../../skia/config -I../../skia/ext -I../../third_party/skia/include/c -I../../third_party/skia/include/config -I../../third_party/skia/include/core -I../../third_party/skia/include/effects -I../../third_party/skia/include/images -I../../third_party/skia/include/lazy -I../../third_party/skia/include/pathops -I../../third_party/skia/include/pdf -I../../third_party/skia/include/pipe -I../../third_party/skia/include/ports -I../../third_party/skia/include/utils -I../../third_party/skia/include/gpu -I../../third_party/skia/src/gpu -I../../third_party/icu/source/common -I../../third_party/icu/source/i18n -I../../third_party/angle/include -I../../third_party/iccjpeg -I../../third_party/libpng -I../../third_party/zlib -I../../third_party/libxml/src/include -I../../third_party/libxml/linux/include -I../../third_party/libxslt -I../../third_party/npapi -I../../third_party/npapi/bindings -I../../third_party/ots/include -I../../third_party/qcms/src -I../../third_party/snappy/src -I../../third_party/snappy/linux -I../../v8/include -fno-strict-aliasing --param=ssp-buffer-size=4 -fstack-protector -funwind-tables -fPIC -pipe -B../../third_party/binutils/Linux_x64/Release/bin -fcolor-diagnostics -fdebug-prefix-map=/b/build/slave/WebKit_Linux_non-Oilpan_Builder/build/src=. -pthread -m64 -march=x86-64 -Wall -Werror -Wextra -Wno-missing-field-initializers -Wno-unused-parameter -Wno-c++11-narrowing -Wno-covered-switch-default -Wno-deprecated-register -Wno-unneeded-internal-declaration -Wno-inconsistent-missing-override -Wno-shift-negative-value -O2 -fno-ident -fdata-sections -ffunction-sections -g0 --sysroot=../../build/linux/debian_wheezy_amd64-sysroot -fvisibility=hidden -Xclang -load -Xclang ../../third_party/llvm-build/Release+Asserts/lib/libFindBadConstructs.so -Xclang -add-plugin -Xclang find-bad-constructs -Xclang -plugin-arg-find-bad-constructs -Xclang check-templates -Xclang -plugin-arg-find-bad-constructs -Xclang follow-macro-expansion -Wheader-hygiene -Wstring-conversion -Wexit-time-destructors -Xclang -load -Xclang ../../third_party/llvm-build/Release+Asserts/lib/libBlinkGCPlugin.so -Xclang -add-plugin -Xclang blink-gc-plugin -DLIBXML_STATIC= -fno-threadsafe-statics -fvisibility-inlines-hidden -std=gnu++11 -fno-rtti -fno-exceptions -c ../../third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp -o obj/third_party/WebKit/Source/core/remaining/StyleBuilderConverter.o
../../third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp:485:39: error: no matching function for call to 'toCSSGridAutoRepeatValue'
CSSValueID autoRepeatID = toCSSGridAutoRepeatValue(currValue)->autoRepeatID();
Original issue's description:
> [css-grid] Store auto-repeat data in ComputedStyle
>
> This patch provides a new CSSValueList subclass which is used by the parser
> to store auto-repeat data which will be later consumed by the
> StyleBuilderConverter. It also adds the required machinery to ComputedStyle
> and StyleGridData.
>
> This is the first step to implement auto-repeat. Follow up patches will
> provide support for:
> * auto-repeat tracks computation
> * grid items placement in auto-repeat tracks
> * auto-repeat tracks computed style
>
> BUG=589460
>
> Committed: https://crrev.com/5778d3531acbd4019a491e9f20fa0785c1d607a8
> Cr-Commit-Position: refs/heads/master@{#380596}
TBR=timloh@chromium.org,cbiesinger@chromium.org,jfernandez@igalia.com,rego@igalia.com,rune@opera.com,mstensho@opera.com,svillar@igalia.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=589460
Review URL: https://codereview.chromium.org/1781153003
Cr-Commit-Position: refs/heads/master@{#380597}
16 files changed, 65 insertions, 277 deletions
diff --git a/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-element-auto-repeat-get-set-expected.txt b/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-element-auto-repeat-get-set-expected.txt index 4c70c74..3953b477 100644 --- a/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-element-auto-repeat-get-set-expected.txt +++ b/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-element-auto-repeat-get-set-expected.txt @@ -4,30 +4,30 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE Test auto-repeat syntax. -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-columns') should be [foo bar] 10px. Was 0px. -PASS element.style.gridTemplateColumns is "repeat(auto-fill, [foo bar] 10px)" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-rows') should be 20px [foo bar]. Was 0px. -PASS element.style.gridTemplateRows is "repeat(auto-fill, 2em [foo bar])" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-columns') should be [foo bar] 800px. Was 0px. -PASS element.style.gridTemplateColumns is "repeat(auto-fill, [foo bar] minmax(10px, 1fr))" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-rows') should be [foo] 20px [bar]. Was 0px. -PASS element.style.gridTemplateRows is "repeat(auto-fill, [foo] minmax(2em, max-content) [bar])" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-columns') should be 100px 20px 20px. Was 20px 20px. -PASS element.style.gridTemplateColumns is "repeat(auto-fill, minmax(10px, 100px)) 20px 20px" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-rows') should be 70px 20px [bar foo] 10px [foo] 10px. Was 70px 10px [foo] 10px [foo]. -PASS element.style.gridTemplateRows is "70px repeat(auto-fill, minmax(2em, max-content) [bar]) [foo] 1em [foo] 1em" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-columns') should be [foo bar] 10px. Was 0px. -PASS element.style.gridTemplateColumns is "repeat(auto-fit, [foo bar] 10px)" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-rows') should be 20px [foo bar]. Was 0px. -PASS element.style.gridTemplateRows is "repeat(auto-fit, 2em [foo bar])" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-columns') should be [foo bar] 800px. Was 0px. -PASS element.style.gridTemplateColumns is "repeat(auto-fit, [foo bar] minmax(10px, 1fr))" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-rows') should be [foo] 20px [bar]. Was 0px. -PASS element.style.gridTemplateRows is "repeat(auto-fit, [foo] minmax(2em, max-content) [bar])" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-columns') should be 10px 20px 20px. Was 20px 20px. -PASS element.style.gridTemplateColumns is "repeat(auto-fit, minmax(10px, min-content)) 20px 20px" -FAIL getComputedStyle(element, '').getPropertyValue('grid-template-rows') should be 60px 20px [bar foo] 10px [foo] 10px. Was 60px 10px [foo] 10px [foo]. -PASS element.style.gridTemplateRows is "10% repeat(auto-fit, minmax(2em, max-content) [bar]) [foo] 1em [foo] 1em" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-columns') is "[foo bar] 10px" +PASS element.style.gridTemplateColumns is "[foo bar] 10px" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-rows') is "20px [foo bar]" +PASS element.style.gridTemplateRows is "2em [foo bar]" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-columns') is "[foo bar] 800px" +PASS element.style.gridTemplateColumns is "[foo bar] minmax(10px, 1fr)" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-rows') is "[foo] 20px [bar]" +PASS element.style.gridTemplateRows is "[foo] minmax(2em, max-content) [bar]" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-columns') is "100px 20px 20px" +PASS element.style.gridTemplateColumns is "minmax(10px, 100px) 20px 20px" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-rows') is "70px 20px [bar foo] 10px [foo] 10px" +PASS element.style.gridTemplateRows is "70px minmax(2em, max-content) [bar] [foo] 1em [foo] 1em" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-columns') is "[foo bar] 10px" +PASS element.style.gridTemplateColumns is "[foo bar] 10px" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-rows') is "20px [foo bar]" +PASS element.style.gridTemplateRows is "2em [foo bar]" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-columns') is "[foo bar] 800px" +PASS element.style.gridTemplateColumns is "[foo bar] minmax(10px, 1fr)" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-rows') is "[foo] 20px [bar]" +PASS element.style.gridTemplateRows is "[foo] minmax(2em, max-content) [bar]" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-columns') is "10px 20px 20px" +PASS element.style.gridTemplateColumns is "minmax(10px, min-content) 20px 20px" +PASS getComputedStyle(element, '').getPropertyValue('grid-template-rows') is "60px 20px [bar foo] 10px [foo] 10px" +PASS element.style.gridTemplateRows is "10% minmax(2em, max-content) [bar] [foo] 1em [foo] 1em" Test invalid repeat syntax. PASS window.getComputedStyle(element, '').getPropertyValue('grid-template-columns') is "none" diff --git a/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-element-auto-repeat-get-set.html b/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-element-auto-repeat-get-set.html index ebfa116..94f18a5 100644 --- a/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-element-auto-repeat-get-set.html +++ b/third_party/WebKit/LayoutTests/fast/css-grid-layout/grid-element-auto-repeat-get-set.html @@ -9,12 +9,12 @@ description('Test that setting/getting grid-template-{columns|rows} with repeat(auto-fill|auto-fit,) works as expected'); debug("Test auto-repeat syntax."); - testGridDefinitionsSetJSValues("repeat(auto-fill, [foo bar] 10px)", "repeat(auto-fill, 2em [foo bar])", "[foo bar] 10px", "20px [foo bar]", "repeat(auto-fill, [foo bar] 10px)", "repeat(auto-fill, 2em [foo bar])"); - testGridDefinitionsSetJSValues("repeat(auto-fill, [foo bar] minmax(10px, 1fr))", "repeat(auto-fill, [foo] minmax(2em, max-content) [bar])", "[foo bar] 800px", "[foo] 20px [bar]", "repeat(auto-fill, [foo bar] minmax(10px, 1fr))", "repeat(auto-fill, [foo] minmax(2em, max-content) [bar])"); - testGridDefinitionsSetJSValues("repeat(auto-fill, minmax(10px, 100px)) repeat(2, 20px)", "repeat(1, 70px) repeat(auto-fill, minmax(2em, max-content) [bar]) repeat(2, [foo] 1em)", "100px 20px 20px", "70px 20px [bar foo] 10px [foo] 10px", "repeat(auto-fill, minmax(10px, 100px)) 20px 20px", "70px repeat(auto-fill, minmax(2em, max-content) [bar]) [foo] 1em [foo] 1em"); - testGridDefinitionsSetJSValues("repeat(auto-fit, [foo bar] 10px)", "repeat(auto-fit, 2em [foo bar])", "[foo bar] 10px", "20px [foo bar]", "repeat(auto-fit, [foo bar] 10px)", "repeat(auto-fit, 2em [foo bar])"); - testGridDefinitionsSetJSValues("repeat(auto-fit, [foo bar] minmax(10px, 1fr))", "repeat(auto-fit, [foo] minmax(2em, max-content) [bar])", "[foo bar] 800px", "[foo] 20px [bar]", "repeat(auto-fit, [foo bar] minmax(10px, 1fr))", "repeat(auto-fit, [foo] minmax(2em, max-content) [bar])"); - testGridDefinitionsSetJSValues("repeat(auto-fit, minmax(10px, min-content)) repeat(2, 20px)", "repeat(1, 10%) repeat(auto-fit, minmax(2em, max-content) [bar]) repeat(2, [foo] 1em)", "10px 20px 20px", "60px 20px [bar foo] 10px [foo] 10px", "repeat(auto-fit, minmax(10px, min-content)) 20px 20px", "10% repeat(auto-fit, minmax(2em, max-content) [bar]) [foo] 1em [foo] 1em"); + testGridDefinitionsSetJSValues("repeat(auto-fill, [foo bar] 10px)", "repeat(auto-fill, 2em [foo bar])", "[foo bar] 10px", "20px [foo bar]", "[foo bar] 10px", "2em [foo bar]"); + testGridDefinitionsSetJSValues("repeat(auto-fill, [foo bar] minmax(10px, 1fr))", "repeat(auto-fill, [foo] minmax(2em, max-content) [bar])", "[foo bar] 800px", "[foo] 20px [bar]", "[foo bar] minmax(10px, 1fr)", "[foo] minmax(2em, max-content) [bar]"); + testGridDefinitionsSetJSValues("repeat(auto-fill, minmax(10px, 100px)) repeat(2, 20px)", "repeat(1, 70px) repeat(auto-fill, minmax(2em, max-content) [bar]) repeat(2, [foo] 1em)", "100px 20px 20px", "70px 20px [bar foo] 10px [foo] 10px", "minmax(10px, 100px) 20px 20px", "70px minmax(2em, max-content) [bar] [foo] 1em [foo] 1em"); + testGridDefinitionsSetJSValues("repeat(auto-fit, [foo bar] 10px)", "repeat(auto-fit, 2em [foo bar])", "[foo bar] 10px", "20px [foo bar]", "[foo bar] 10px", "2em [foo bar]"); + testGridDefinitionsSetJSValues("repeat(auto-fit, [foo bar] minmax(10px, 1fr))", "repeat(auto-fit, [foo] minmax(2em, max-content) [bar])", "[foo bar] 800px", "[foo] 20px [bar]", "[foo bar] minmax(10px, 1fr)", "[foo] minmax(2em, max-content) [bar]"); + testGridDefinitionsSetJSValues("repeat(auto-fit, minmax(10px, min-content)) repeat(2, 20px)", "repeat(1, 10%) repeat(auto-fit, minmax(2em, max-content) [bar]) repeat(2, [foo] 1em)", "10px 20px 20px", "60px 20px [bar foo] 10px [foo] 10px", "minmax(10px, min-content) 20px 20px", "10% minmax(2em, max-content) [bar] [foo] 1em [foo] 1em"); debug(""); debug("Test invalid repeat syntax."); diff --git a/third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl b/third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl index 6097cfc..61d5c25 100644 --- a/third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl +++ b/third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl @@ -461,27 +461,15 @@ static bool borderImageLengthMatchesAllSides(const BorderImageLengthBox& borderI {{declare_value_function(property_id)}} { Vector<GridTrackSize> trackSizes; - Vector<GridTrackSize> autoRepeatTrackSizes; - size_t autoRepeatInsertionPoint; NamedGridLinesMap namedGridLines; OrderedNamedGridLines orderedNamedGridLines; - NamedGridLinesMap autoRepeatNamedGridLines; - OrderedNamedGridLines autoRepeatOrderedNamedGridLines; - AutoRepeatType autoRepeatType; - StyleBuilderConverter::convertGridTrackList(*value, trackSizes, namedGridLines, orderedNamedGridLines, autoRepeatTrackSizes, autoRepeatNamedGridLines, autoRepeatOrderedNamedGridLines, autoRepeatInsertionPoint, autoRepeatType, state); + StyleBuilderConverter::convertGridTrackList(*value, trackSizes, namedGridLines, orderedNamedGridLines, state); const NamedGridAreaMap& namedGridAreas = state.style()->namedGridArea(); if (!namedGridAreas.isEmpty()) StyleBuilderConverter::createImplicitNamedGridLinesFromGridArea(namedGridAreas, namedGridLines, For{{type}}s); state.style()->setGridTemplate{{type}}s(trackSizes); state.style()->setNamedGrid{{type}}Lines(namedGridLines); state.style()->setOrderedNamedGrid{{type}}Lines(orderedNamedGridLines); - if (autoRepeatTrackSizes.size()) { - state.style()->setGridAutoRepeat{{type}}s(autoRepeatTrackSizes); - state.style()->setGridAutoRepeat{{type}}sInsertionPoint(autoRepeatInsertionPoint); - state.style()->setAutoRepeatNamedGrid{{type}}Lines(autoRepeatNamedGridLines); - state.style()->setAutoRepeatOrderedNamedGrid{{type}}Lines(autoRepeatOrderedNamedGridLines); - state.style()->setGridAutoRepeatType(autoRepeatType); - } } {% endmacro %} {{apply_grid_template('CSSPropertyGridTemplateColumns', 'Column')}} diff --git a/third_party/WebKit/Source/core/core.gypi b/third_party/WebKit/Source/core/core.gypi index 87d2d13..3cdb438 100644 --- a/third_party/WebKit/Source/core/core.gypi +++ b/third_party/WebKit/Source/core/core.gypi @@ -1135,8 +1135,6 @@ 'css/CSSFunctionValue.h', 'css/CSSGradientValue.cpp', 'css/CSSGradientValue.h', - 'css/CSSGridAutoRepeatValue.h', - 'css/CSSGridAutoRepeatValue.cpp', 'css/CSSGridLineNamesValue.cpp', 'css/CSSGridLineNamesValue.h', 'css/CSSGridTemplateAreasValue.cpp', diff --git a/third_party/WebKit/Source/core/css/CSSGridAutoRepeatValue.cpp b/third_party/WebKit/Source/core/css/CSSGridAutoRepeatValue.cpp deleted file mode 100644 index 238c6ed..0000000 --- a/third_party/WebKit/Source/core/css/CSSGridAutoRepeatValue.cpp +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2016 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "core/css/CSSGridAutoRepeatValue.h" - -#include "wtf/text/StringBuilder.h" - -namespace blink { - -String CSSGridAutoRepeatValue::customCSSText() const -{ - StringBuilder result; - result.append("repeat("); - result.append(getValueName(autoRepeatID())); - result.append(", "); - result.append(CSSValueList::customCSSText()); - result.append(")"); - return result.toString(); -} - -} // namespace blink diff --git a/third_party/WebKit/Source/core/css/CSSGridAutoRepeatValue.h b/third_party/WebKit/Source/core/css/CSSGridAutoRepeatValue.h deleted file mode 100644 index 1b69f93..0000000 --- a/third_party/WebKit/Source/core/css/CSSGridAutoRepeatValue.h +++ /dev/null @@ -1,51 +0,0 @@ -// Copyright 2016 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef CSSGridAutoRepeatValue_h -#define CSSGridAutoRepeatValue_h - -#include "core/CSSValueKeywords.h" -#include "core/css/CSSValueList.h" - -namespace blink { - -// CSSGridAutoRepeatValue stores the track sizes and line numbers when the auto-repeat -// syntax is used -// -// Right now the auto-repeat syntax is as follows: -// <auto-repeat> = repeat( [ auto-fill | auto-fit ], <line-names>? <fixed-size> <line-names>? ) -// -// meaning that only one fixed size track is allowed. It could be argued that a different -// class storing two CSSGridLineNamesValue and one CSSValue (for the track size) fits -// better but the CSSWG has left the door open to allow more than one track in the -// future. That's why we're using a list, it's prepared for future changes and it also -// allows us to keep the parsing algorithm almost intact. -class CSSGridAutoRepeatValue : public CSSValueList { -public: - static PassRefPtrWillBeRawPtr<CSSGridAutoRepeatValue> create(CSSValueID id) - { - return adoptRefWillBeNoop(new CSSGridAutoRepeatValue(id)); - } - - String customCSSText() const; - CSSValueID autoRepeatID() const { return m_autoRepeatID; } - - DEFINE_INLINE_TRACE_AFTER_DISPATCH() { CSSValueList::traceAfterDispatch(visitor); } - -private: - CSSGridAutoRepeatValue(CSSValueID id) - : CSSValueList(GridAutoRepeatClass, SpaceSeparator) - , m_autoRepeatID(id) - { - ASSERT(id == CSSValueAutoFill || id == CSSValueAutoFit); - } - - const CSSValueID m_autoRepeatID; -}; - -DEFINE_CSS_VALUE_TYPE_CASTS(CSSGridAutoRepeatValue, isGridAutoRepeatValue()); - -} // namespace blink - -#endif // CSSGridAutoRepeatValue_h diff --git a/third_party/WebKit/Source/core/css/CSSValue.cpp b/third_party/WebKit/Source/core/css/CSSValue.cpp index 7481533..4f3dd60 100644 --- a/third_party/WebKit/Source/core/css/CSSValue.cpp +++ b/third_party/WebKit/Source/core/css/CSSValue.cpp @@ -39,7 +39,6 @@ #include "core/css/CSSFontFeatureValue.h" #include "core/css/CSSFunctionValue.h" #include "core/css/CSSGradientValue.h" -#include "core/css/CSSGridAutoRepeatValue.h" #include "core/css/CSSGridLineNamesValue.h" #include "core/css/CSSGridTemplateAreasValue.h" #include "core/css/CSSImageSetValue.h" @@ -138,8 +137,6 @@ bool CSSValue::equals(const CSSValue& other) const return compareCSSValues<CSSInitialValue>(*this, other); case UnsetClass: return compareCSSValues<CSSUnsetValue>(*this, other); - case GridAutoRepeatClass: - return compareCSSValues<CSSGridAutoRepeatValue>(*this, other); case GridLineNamesClass: return compareCSSValues<CSSGridLineNamesValue>(*this, other); case GridTemplateAreasClass: @@ -226,8 +223,6 @@ String CSSValue::cssText() const return toCSSUnsetValue(this)->customCSSText(); case InitialClass: return toCSSInitialValue(this)->customCSSText(); - case GridAutoRepeatClass: - return toCSSGridAutoRepeatValue(this)->customCSSText(); case GridLineNamesClass: return toCSSGridLineNamesValue(this)->customCSSText(); case GridTemplateAreasClass: @@ -331,9 +326,6 @@ void CSSValue::destroy() case UnsetClass: delete toCSSUnsetValue(this); return; - case GridAutoRepeatClass: - delete toCSSGridAutoRepeatValue(this); - return; case GridLineNamesClass: delete toCSSGridLineNamesValue(this); return; @@ -455,9 +447,6 @@ void CSSValue::finalizeGarbageCollectedObject() case UnsetClass: toCSSUnsetValue(this)->~CSSUnsetValue(); return; - case GridAutoRepeatClass: - toCSSGridAutoRepeatValue(this)->~CSSGridAutoRepeatValue(); - return; case GridLineNamesClass: toCSSGridLineNamesValue(this)->~CSSGridLineNamesValue(); return; @@ -579,9 +568,6 @@ DEFINE_TRACE(CSSValue) case UnsetClass: toCSSUnsetValue(this)->traceAfterDispatch(visitor); return; - case GridAutoRepeatClass: - toCSSGridAutoRepeatValue(this)->traceAfterDispatch(visitor); - return; case GridLineNamesClass: toCSSGridLineNamesValue(this)->traceAfterDispatch(visitor); return; diff --git a/third_party/WebKit/Source/core/css/CSSValue.h b/third_party/WebKit/Source/core/css/CSSValue.h index 33eb456..8b52da1 100644 --- a/third_party/WebKit/Source/core/css/CSSValue.h +++ b/third_party/WebKit/Source/core/css/CSSValue.h @@ -108,7 +108,6 @@ public: bool isGridLineNamesValue() const { return m_classType == GridLineNamesClass; } bool isCustomPropertyDeclaration() const { return m_classType == CustomPropertyDeclarationClass; } bool isVariableReferenceValue() const { return m_classType == VariableReferenceClass; } - bool isGridAutoRepeatValue() const { return m_classType == GridAutoRepeatClass; } bool hasFailedOrCanceledSubresources() const; @@ -183,7 +182,6 @@ protected: FunctionClass, ImageSetClass, GridLineNamesClass, - GridAutoRepeatClass, // Do not append non-list class types here. }; diff --git a/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp b/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp index 8215810..0ed1d88 100644 --- a/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp +++ b/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp @@ -566,15 +566,12 @@ static void addValuesForNamedGridLinesAtIndex(const OrderedNamedGridLines& order static PassRefPtrWillBeRawPtr<CSSValue> valueForGridTrackList(GridTrackSizingDirection direction, const LayoutObject* layoutObject, const ComputedStyle& style) { - bool isRowAxis = direction == ForColumns; - const Vector<GridTrackSize>& trackSizes = isRowAxis ? style.gridTemplateColumns() : style.gridTemplateRows(); - const Vector<GridTrackSize>& autoRepeatTrackSizes = isRowAxis ? style.gridAutoRepeatColumns() : style.gridAutoRepeatRows(); - const OrderedNamedGridLines& orderedNamedGridLines = isRowAxis ? style.orderedNamedGridColumnLines() : style.orderedNamedGridRowLines(); - + const Vector<GridTrackSize>& trackSizes = direction == ForColumns ? style.gridTemplateColumns() : style.gridTemplateRows(); + const OrderedNamedGridLines& orderedNamedGridLines = direction == ForColumns ? style.orderedNamedGridColumnLines() : style.orderedNamedGridRowLines(); bool isLayoutGrid = layoutObject && layoutObject->isLayoutGrid(); // Handle the 'none' case. - bool trackListIsEmpty = trackSizes.isEmpty() && autoRepeatTrackSizes.isEmpty(); + bool trackListIsEmpty = trackSizes.isEmpty(); if (isLayoutGrid && trackListIsEmpty) { // For grids we should consider every listed track, whether implicitly or explicitly created. If we don't have // any explicit track and there are no children then there are no implicit tracks. We cannot simply check the diff --git a/third_party/WebKit/Source/core/css/parser/LegacyCSSPropertyParser.cpp b/third_party/WebKit/Source/core/css/parser/LegacyCSSPropertyParser.cpp index cadf767..4ed490c 100644 --- a/third_party/WebKit/Source/core/css/parser/LegacyCSSPropertyParser.cpp +++ b/third_party/WebKit/Source/core/css/parser/LegacyCSSPropertyParser.cpp @@ -29,7 +29,6 @@ #include "core/StylePropertyShorthand.h" #include "core/css/CSSCustomIdentValue.h" #include "core/css/CSSFunctionValue.h" -#include "core/css/CSSGridAutoRepeatValue.h" #include "core/css/CSSGridLineNamesValue.h" #include "core/css/CSSPrimitiveValueMappings.h" #include "core/css/CSSValuePair.h" @@ -774,28 +773,6 @@ bool CSSPropertyParser::parseGridLineNames(CSSParserValueList& inputList, CSSVal return true; } -static bool allTracksAreFixedSized(CSSValueList& valueList) -{ - for (auto value : valueList) { - if (value->isGridLineNamesValue()) - continue; - // The auto-repeat value holds a <fixed-size> = <fixed-breadth> | minmax( <fixed-breadth>, <track-breadth> ) - if (value->isGridAutoRepeatValue()) { - if (!allTracksAreFixedSized(toCSSValueList(*value))) - return false; - continue; - } - ASSERT(value->isPrimitiveValue() || (value->isFunctionValue() && toCSSFunctionValue(*value).item(0))); - const CSSPrimitiveValue& primitiveValue = value->isPrimitiveValue() - ? toCSSPrimitiveValue(*value) - : toCSSPrimitiveValue(*toCSSFunctionValue(*value).item(0)); - CSSValueID valueID = primitiveValue.getValueID(); - if (valueID == CSSValueMinContent || valueID == CSSValueMaxContent || valueID == CSSValueAuto || primitiveValue.isFlex()) - return false; - } - return true; -} - PassRefPtrWillBeRawPtr<CSSValue> CSSPropertyParser::parseGridTrackList() { ASSERT(RuntimeEnabledFeatures::cssGridLayoutEnabled()); @@ -842,8 +819,19 @@ PassRefPtrWillBeRawPtr<CSSValue> CSSPropertyParser::parseGridTrackList() // <auto-repeat> requires definite minimum track sizes in order to compute the number of repetitions. // The above while loop detects those appearances after the <auto-repeat> but not the ones before. - if (seenAutoRepeat && !allTracksAreFixedSized(*values)) - return nullptr; + if (seenAutoRepeat) { + for (auto value : *values) { + if (value->isGridLineNamesValue()) + continue; + ASSERT(value->isPrimitiveValue() || (value->isFunctionValue() && toCSSFunctionValue(*value).item(0))); + const CSSPrimitiveValue& primitiveValue = value->isPrimitiveValue() + ? toCSSPrimitiveValue(*value) + : toCSSPrimitiveValue(*toCSSFunctionValue(*value).item(0)); + CSSValueID valueID = primitiveValue.getValueID(); + if (valueID == CSSValueMinContent || valueID == CSSValueMaxContent || valueID == CSSValueAuto || primitiveValue.isFlex()) + return nullptr; + } + } return values; } @@ -863,7 +851,7 @@ bool CSSPropertyParser::parseGridTrackRepeatFunction(CSSValueList& list, bool& i // because it will be computed later, let's set it to 1. size_t repetitions = isAutoRepeat ? 1 : clampTo<size_t>(currentValue->fValue, 0, kGridMaxTracks); - RefPtrWillBeRawPtr<CSSValueList> repeatedValues = isAutoRepeat ? CSSGridAutoRepeatValue::create(currentValue->id) : CSSValueList::createSpaceSeparated(); + RefPtrWillBeRawPtr<CSSValueList> repeatedValues = CSSValueList::createSpaceSeparated(); arguments->next(); // Skip the repetition count. arguments->next(); // Skip the comma. @@ -893,17 +881,13 @@ bool CSSPropertyParser::parseGridTrackRepeatFunction(CSSValueList& list, bool& i if (!numberOfTracks) return false; - if (isAutoRepeat) { - list.append(repeatedValues.release()); - } else { - // We clamp the number of repetitions to a multiple of the repeat() track list's size, while staying below the max - // grid size. - repetitions = std::min(repetitions, kGridMaxTracks / numberOfTracks); + // We clamp the number of repetitions to a multiple of the repeat() track list's size, while staying below the max + // grid size. + repetitions = std::min(repetitions, kGridMaxTracks / numberOfTracks); - for (size_t i = 0; i < repetitions; ++i) { - for (size_t j = 0; j < repeatedValues->length(); ++j) - list.append(repeatedValues->item(j)); - } + for (size_t i = 0; i < repetitions; ++i) { + for (size_t j = 0; j < repeatedValues->length(); ++j) + list.append(repeatedValues->item(j)); } // parseGridTrackSize iterated over the repeat arguments, move to the next value. diff --git a/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp b/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp index 8ee0430..fd34261 100644 --- a/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp +++ b/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp @@ -31,7 +31,6 @@ #include "core/css/CSSContentDistributionValue.h" #include "core/css/CSSFontFeatureValue.h" #include "core/css/CSSFunctionValue.h" -#include "core/css/CSSGridAutoRepeatValue.h" #include "core/css/CSSGridLineNamesValue.h" #include "core/css/CSSPathValue.h" #include "core/css/CSSPrimitiveValueMappings.h" @@ -452,20 +451,7 @@ GridTrackSize StyleBuilderConverter::convertGridTrackSize(StyleResolverState& st return GridTrackSize(minTrackBreadth, maxTrackBreadth); } -static void convertGridLineNamesList(const CSSValue& value, size_t currentNamedGridLine, NamedGridLinesMap& namedGridLines, OrderedNamedGridLines& orderedNamedGridLines) -{ - ASSERT(value.isGridLineNamesValue()); - - for (auto& namedGridLineValue : toCSSValueList(value)) { - String namedGridLine = toCSSCustomIdentValue(*namedGridLineValue).value(); - NamedGridLinesMap::AddResult result = namedGridLines.add(namedGridLine, Vector<size_t>()); - result.storedValue->value.append(currentNamedGridLine); - OrderedNamedGridLines::AddResult orderedInsertionResult = orderedNamedGridLines.add(currentNamedGridLine, Vector<String>()); - orderedInsertionResult.storedValue->value.append(namedGridLine); - } -} - -void StyleBuilderConverter::convertGridTrackList(const CSSValue& value, Vector<GridTrackSize>& trackSizes, NamedGridLinesMap& namedGridLines, OrderedNamedGridLines& orderedNamedGridLines, Vector<GridTrackSize>& autoRepeatTrackSizes, NamedGridLinesMap& autoRepeatNamedGridLines, OrderedNamedGridLines& autoRepeatOrderedNamedGridLines, size_t& autoRepeatInsertionPoint, AutoRepeatType &autoRepeatType, StyleResolverState& state) +void StyleBuilderConverter::convertGridTrackList(const CSSValue& value, Vector<GridTrackSize>& trackSizes, NamedGridLinesMap& namedGridLines, OrderedNamedGridLines& orderedNamedGridLines, StyleResolverState& state) { if (value.isPrimitiveValue()) { ASSERT(toCSSPrimitiveValue(value).getValueID() == CSSValueNone); @@ -473,27 +459,15 @@ void StyleBuilderConverter::convertGridTrackList(const CSSValue& value, Vector<G } size_t currentNamedGridLine = 0; - for (auto currValue : toCSSValueList(value)) { + for (auto& currValue : toCSSValueList(value)) { if (currValue->isGridLineNamesValue()) { - convertGridLineNamesList(*currValue, currentNamedGridLine, namedGridLines, orderedNamedGridLines); - continue; - } - - if (currValue->isGridAutoRepeatValue()) { - ASSERT(autoRepeatTrackSizes.isEmpty()); - size_t autoRepeatIndex = 0; - CSSValueID autoRepeatID = toCSSGridAutoRepeatValue(currValue)->autoRepeatID(); - ASSERT(autoRepeatID == CSSValueAutoFill || autoRepeatID == CSSValueAutoFit); - autoRepeatType = autoRepeatID == CSSValueAutoFill ? AutoFill : AutoFit; - for (auto autoRepeatValue : toCSSValueList(*currValue)) { - if (autoRepeatValue->isGridLineNamesValue()) { - convertGridLineNamesList(*autoRepeatValue, autoRepeatIndex, autoRepeatNamedGridLines, autoRepeatOrderedNamedGridLines); - continue; - } - ++autoRepeatIndex; - autoRepeatTrackSizes.append(convertGridTrackSize(state, *autoRepeatValue)); + for (auto& namedGridLineValue : toCSSGridLineNamesValue(*currValue)) { + String namedGridLine = toCSSCustomIdentValue(*namedGridLineValue).value(); + NamedGridLinesMap::AddResult result = namedGridLines.add(namedGridLine, Vector<size_t>()); + result.storedValue->value.append(currentNamedGridLine); + OrderedNamedGridLines::AddResult orderedInsertionResult = orderedNamedGridLines.add(currentNamedGridLine, Vector<String>()); + orderedInsertionResult.storedValue->value.append(namedGridLine); } - autoRepeatInsertionPoint = currentNamedGridLine++; continue; } @@ -503,7 +477,7 @@ void StyleBuilderConverter::convertGridTrackList(const CSSValue& value, Vector<G // The parser should have rejected any <track-list> without any <track-size> as // this is not conformant to the syntax. - ASSERT(!trackSizes.isEmpty() || !autoRepeatTrackSizes.isEmpty()); + ASSERT(!trackSizes.isEmpty()); } void StyleBuilderConverter::convertOrderedNamedGridLinesMapToNamedGridLinesMap(const OrderedNamedGridLines& orderedNamedGridLines, NamedGridLinesMap& namedGridLines) diff --git a/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.h b/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.h index e328c8e..22fd808 100644 --- a/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.h +++ b/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.h @@ -96,9 +96,7 @@ public: static float convertTextStrokeWidth(StyleResolverState&, const CSSValue&); static TransformOrigin convertTransformOrigin(StyleResolverState&, const CSSValue&); - static void convertGridTrackList(const CSSValue&, Vector<GridTrackSize>&, NamedGridLinesMap&, OrderedNamedGridLines&, - Vector<GridTrackSize>& autoRepeatTrackSizes, NamedGridLinesMap&, OrderedNamedGridLines&, - size_t& autoRepeatInsertionPoint, AutoRepeatType&, StyleResolverState&); + static void convertGridTrackList(const CSSValue&, Vector<GridTrackSize>&, NamedGridLinesMap&, OrderedNamedGridLines&, StyleResolverState&); static void createImplicitNamedGridLinesFromGridArea(const NamedGridAreaMap&, NamedGridLinesMap&, GridTrackSizingDirection); static void convertOrderedNamedGridLinesMapToNamedGridLinesMap(const OrderedNamedGridLines&, NamedGridLinesMap&); diff --git a/third_party/WebKit/Source/core/style/ComputedStyle.h b/third_party/WebKit/Source/core/style/ComputedStyle.h index 36a0222..7540622 100644 --- a/third_party/WebKit/Source/core/style/ComputedStyle.h +++ b/third_party/WebKit/Source/core/style/ComputedStyle.h @@ -816,19 +816,10 @@ public: const Vector<GridTrackSize>& gridTemplateColumns() const { return rareNonInheritedData->m_grid->m_gridTemplateColumns; } const Vector<GridTrackSize>& gridTemplateRows() const { return rareNonInheritedData->m_grid->m_gridTemplateRows; } - const Vector<GridTrackSize>& gridAutoRepeatColumns() const { return rareNonInheritedData->m_grid->m_gridAutoRepeatColumns; } - const Vector<GridTrackSize>& gridAutoRepeatRows() const { return rareNonInheritedData->m_grid->m_gridAutoRepeatRows; } - size_t gridAutoRepeatColumnsInsertionPoint() const { return rareNonInheritedData->m_grid->m_autoRepeatColumnsInsertionPoint; } - size_t gridAutoRepeatRowsInsertionPoint() const { return rareNonInheritedData->m_grid->m_autoRepeatRowsInsertionPoint; } - AutoRepeatType gridAutoRepeatType() const { return rareNonInheritedData->m_grid->m_autoRepeatType; } const NamedGridLinesMap& namedGridColumnLines() const { return rareNonInheritedData->m_grid->m_namedGridColumnLines; } const NamedGridLinesMap& namedGridRowLines() const { return rareNonInheritedData->m_grid->m_namedGridRowLines; } const OrderedNamedGridLines& orderedNamedGridColumnLines() const { return rareNonInheritedData->m_grid->m_orderedNamedGridColumnLines; } const OrderedNamedGridLines& orderedNamedGridRowLines() const { return rareNonInheritedData->m_grid->m_orderedNamedGridRowLines; } - const NamedGridLinesMap& autoRepeatNamedGridColumnLines() const { return rareNonInheritedData->m_grid->m_autoRepeatNamedGridColumnLines; } - const NamedGridLinesMap& autoRepeatNamedGridRowLines() const { return rareNonInheritedData->m_grid->m_autoRepeatNamedGridRowLines; } - const OrderedNamedGridLines& autoRepeatOrderedNamedGridColumnLines() const { return rareNonInheritedData->m_grid->m_autoRepeatOrderedNamedGridColumnLines; } - const OrderedNamedGridLines& autoRepeatOrderedNamedGridRowLines() const { return rareNonInheritedData->m_grid->m_autoRepeatOrderedNamedGridRowLines; } const NamedGridAreaMap& namedGridArea() const { return rareNonInheritedData->m_grid->m_namedGridArea; } size_t namedGridAreaRowCount() const { return rareNonInheritedData->m_grid->m_namedGridAreaRowCount; } size_t namedGridAreaColumnCount() const { return rareNonInheritedData->m_grid->m_namedGridAreaColumnCount; } @@ -1377,19 +1368,10 @@ public: void setGridAutoRows(const GridTrackSize& length) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_gridAutoRows, length); } void setGridTemplateColumns(const Vector<GridTrackSize>& lengths) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_gridTemplateColumns, lengths); } void setGridTemplateRows(const Vector<GridTrackSize>& lengths) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_gridTemplateRows, lengths); } - void setGridAutoRepeatColumns(const Vector<GridTrackSize>& trackSizes) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_gridAutoRepeatColumns, trackSizes); } - void setGridAutoRepeatRows(const Vector<GridTrackSize>& trackSizes) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_gridAutoRepeatRows, trackSizes); } - void setGridAutoRepeatColumnsInsertionPoint(const size_t insertionPoint) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_autoRepeatColumnsInsertionPoint, insertionPoint); } - void setGridAutoRepeatRowsInsertionPoint(const size_t insertionPoint) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_autoRepeatRowsInsertionPoint, insertionPoint); } - void setGridAutoRepeatType(const AutoRepeatType autoRepeatType) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_autoRepeatType, autoRepeatType); } void setNamedGridColumnLines(const NamedGridLinesMap& namedGridColumnLines) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_namedGridColumnLines, namedGridColumnLines); } void setNamedGridRowLines(const NamedGridLinesMap& namedGridRowLines) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_namedGridRowLines, namedGridRowLines); } void setOrderedNamedGridColumnLines(const OrderedNamedGridLines& orderedNamedGridColumnLines) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_orderedNamedGridColumnLines, orderedNamedGridColumnLines); } void setOrderedNamedGridRowLines(const OrderedNamedGridLines& orderedNamedGridRowLines) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_orderedNamedGridRowLines, orderedNamedGridRowLines); } - void setAutoRepeatNamedGridColumnLines(const NamedGridLinesMap& namedGridColumnLines) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_autoRepeatNamedGridColumnLines, namedGridColumnLines); } - void setAutoRepeatNamedGridRowLines(const NamedGridLinesMap& namedGridRowLines) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_autoRepeatNamedGridRowLines, namedGridRowLines); } - void setAutoRepeatOrderedNamedGridColumnLines(const OrderedNamedGridLines& orderedNamedGridColumnLines) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_autoRepeatOrderedNamedGridColumnLines, orderedNamedGridColumnLines); } - void setAutoRepeatOrderedNamedGridRowLines(const OrderedNamedGridLines& orderedNamedGridRowLines) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_autoRepeatOrderedNamedGridRowLines, orderedNamedGridRowLines); } void setNamedGridArea(const NamedGridAreaMap& namedGridArea) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_namedGridArea, namedGridArea); } void setNamedGridAreaRowCount(size_t rowCount) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_namedGridAreaRowCount, rowCount); } void setNamedGridAreaColumnCount(size_t columnCount) { SET_NESTED_VAR(rareNonInheritedData, m_grid, m_namedGridAreaColumnCount, columnCount); } @@ -1812,9 +1794,6 @@ public: // The initial value is 'none' for grid tracks. static Vector<GridTrackSize> initialGridTemplateColumns() { return Vector<GridTrackSize>(); } static Vector<GridTrackSize> initialGridTemplateRows() { return Vector<GridTrackSize>(); } - static Vector<GridTrackSize> initialGridAutoRepeatTracks() { return Vector<GridTrackSize>(); } - static size_t initialGridAutoRepeatInsertionPoint() { return 0; } - static AutoRepeatType initialGridAutoRepeatType() { return NoAutoRepeat; } static GridAutoFlow initialGridAutoFlow() { return AutoFlowRow; } diff --git a/third_party/WebKit/Source/core/style/ComputedStyleConstants.h b/third_party/WebKit/Source/core/style/ComputedStyleConstants.h index 6d9f77b..8e03c3d 100644 --- a/third_party/WebKit/Source/core/style/ComputedStyleConstants.h +++ b/third_party/WebKit/Source/core/style/ComputedStyleConstants.h @@ -605,12 +605,6 @@ enum ScrollSnapType { ScrollSnapTypeProximity }; -enum AutoRepeatType { - NoAutoRepeat, - AutoFill, - AutoFit -}; - } // namespace blink #endif // ComputedStyleConstants_h diff --git a/third_party/WebKit/Source/core/style/StyleGridData.cpp b/third_party/WebKit/Source/core/style/StyleGridData.cpp index 20f1588..f780397 100644 --- a/third_party/WebKit/Source/core/style/StyleGridData.cpp +++ b/third_party/WebKit/Source/core/style/StyleGridData.cpp @@ -36,10 +36,6 @@ StyleGridData::StyleGridData() , m_namedGridRowLines(ComputedStyle::initialNamedGridRowLines()) , m_orderedNamedGridColumnLines(ComputedStyle::initialOrderedNamedGridColumnLines()) , m_orderedNamedGridRowLines(ComputedStyle::initialOrderedNamedGridRowLines()) - , m_autoRepeatNamedGridColumnLines(ComputedStyle::initialNamedGridColumnLines()) - , m_autoRepeatNamedGridRowLines(ComputedStyle::initialNamedGridRowLines()) - , m_autoRepeatOrderedNamedGridColumnLines(ComputedStyle::initialOrderedNamedGridColumnLines()) - , m_autoRepeatOrderedNamedGridRowLines(ComputedStyle::initialOrderedNamedGridRowLines()) , m_gridAutoFlow(ComputedStyle::initialGridAutoFlow()) , m_gridAutoRows(ComputedStyle::initialGridAutoRows()) , m_gridAutoColumns(ComputedStyle::initialGridAutoColumns()) @@ -48,11 +44,6 @@ StyleGridData::StyleGridData() , m_namedGridAreaColumnCount(ComputedStyle::initialNamedGridAreaCount()) , m_gridColumnGap(ComputedStyle::initialGridColumnGap()) , m_gridRowGap(ComputedStyle::initialGridRowGap()) - , m_gridAutoRepeatColumns(ComputedStyle::initialGridAutoRepeatTracks()) - , m_gridAutoRepeatRows(ComputedStyle::initialGridAutoRepeatTracks()) - , m_autoRepeatColumnsInsertionPoint(ComputedStyle::initialGridAutoRepeatInsertionPoint()) - , m_autoRepeatRowsInsertionPoint(ComputedStyle::initialGridAutoRepeatInsertionPoint()) - , m_autoRepeatType(ComputedStyle::initialGridAutoRepeatType()) { } @@ -64,10 +55,6 @@ StyleGridData::StyleGridData(const StyleGridData& o) , m_namedGridRowLines(o.m_namedGridRowLines) , m_orderedNamedGridColumnLines(o.m_orderedNamedGridColumnLines) , m_orderedNamedGridRowLines(o.m_orderedNamedGridRowLines) - , m_autoRepeatNamedGridColumnLines(o.m_namedGridColumnLines) - , m_autoRepeatNamedGridRowLines(o.m_namedGridRowLines) - , m_autoRepeatOrderedNamedGridColumnLines(o.m_orderedNamedGridColumnLines) - , m_autoRepeatOrderedNamedGridRowLines(o.m_orderedNamedGridRowLines) , m_gridAutoFlow(o.m_gridAutoFlow) , m_gridAutoRows(o.m_gridAutoRows) , m_gridAutoColumns(o.m_gridAutoColumns) @@ -76,11 +63,6 @@ StyleGridData::StyleGridData(const StyleGridData& o) , m_namedGridAreaColumnCount(o.m_namedGridAreaColumnCount) , m_gridColumnGap(o.m_gridColumnGap) , m_gridRowGap(o.m_gridRowGap) - , m_gridAutoRepeatColumns(o.m_gridAutoRepeatColumns) - , m_gridAutoRepeatRows(o.m_gridAutoRepeatRows) - , m_autoRepeatColumnsInsertionPoint(o.m_autoRepeatColumnsInsertionPoint) - , m_autoRepeatRowsInsertionPoint(o.m_autoRepeatRowsInsertionPoint) - , m_autoRepeatType(o.m_autoRepeatType) { } diff --git a/third_party/WebKit/Source/core/style/StyleGridData.h b/third_party/WebKit/Source/core/style/StyleGridData.h index e47bddc..fa5fae1 100644 --- a/third_party/WebKit/Source/core/style/StyleGridData.h +++ b/third_party/WebKit/Source/core/style/StyleGridData.h @@ -50,14 +50,9 @@ public: && m_gridAutoFlow == o.m_gridAutoFlow && m_gridAutoRows == o.m_gridAutoRows && m_gridAutoColumns == o.m_gridAutoColumns && m_namedGridColumnLines == o.m_namedGridColumnLines && m_namedGridRowLines == o.m_namedGridRowLines && m_orderedNamedGridColumnLines == o.m_orderedNamedGridColumnLines && m_orderedNamedGridRowLines == o.m_orderedNamedGridRowLines - && m_autoRepeatNamedGridColumnLines == o.m_autoRepeatNamedGridColumnLines && m_autoRepeatNamedGridRowLines == o.m_autoRepeatNamedGridRowLines - && m_autoRepeatOrderedNamedGridColumnLines == o.m_autoRepeatOrderedNamedGridColumnLines && m_autoRepeatOrderedNamedGridRowLines == o.m_autoRepeatOrderedNamedGridRowLines && m_namedGridArea == o.m_namedGridArea && m_namedGridArea == o.m_namedGridArea && m_namedGridAreaRowCount == o.m_namedGridAreaRowCount && m_namedGridAreaColumnCount == o.m_namedGridAreaColumnCount - && m_gridColumnGap == o.m_gridColumnGap && m_gridRowGap == o.m_gridRowGap - && m_gridAutoRepeatColumns == o.m_gridAutoRepeatColumns && m_gridAutoRepeatRows == o.m_gridAutoRepeatRows - && m_autoRepeatColumnsInsertionPoint == o.m_autoRepeatColumnsInsertionPoint && m_autoRepeatRowsInsertionPoint == o.m_autoRepeatRowsInsertionPoint - && m_autoRepeatType == o.m_autoRepeatType; + && m_gridColumnGap == o.m_gridColumnGap && m_gridRowGap == o.m_gridRowGap; } bool operator!=(const StyleGridData& o) const @@ -76,11 +71,6 @@ public: OrderedNamedGridLines m_orderedNamedGridColumnLines; OrderedNamedGridLines m_orderedNamedGridRowLines; - NamedGridLinesMap m_autoRepeatNamedGridColumnLines; - NamedGridLinesMap m_autoRepeatNamedGridRowLines; - OrderedNamedGridLines m_autoRepeatOrderedNamedGridColumnLines; - OrderedNamedGridLines m_autoRepeatOrderedNamedGridRowLines; - unsigned m_gridAutoFlow : GridAutoFlowBits; GridTrackSize m_gridAutoRows; @@ -95,13 +85,6 @@ public: Length m_gridColumnGap; Length m_gridRowGap; - Vector<GridTrackSize> m_gridAutoRepeatColumns; - Vector<GridTrackSize> m_gridAutoRepeatRows; - - size_t m_autoRepeatColumnsInsertionPoint; - size_t m_autoRepeatRowsInsertionPoint; - - AutoRepeatType m_autoRepeatType; private: StyleGridData(); StyleGridData(const StyleGridData&); |
