Diff
Modified: trunk/LayoutTests/ChangeLog (215604 => 215605)
--- trunk/LayoutTests/ChangeLog 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/LayoutTests/ChangeLog 2017-04-21 06:04:20 UTC (rev 215605)
@@ -1,3 +1,18 @@
+2017-04-20 Commit Queue <[email protected]>
+
+ Unreviewed, rolling out r215597.
+ https://bugs.webkit.org/show_bug.cgi?id=171102
+
+ Made all tests crash under GuardMalloc (Requested by ap on
+ #webkit).
+
+ Reverted changeset:
+
+ "Expose obscured insets to web content (as "safe area
+ insets")"
+ https://bugs.webkit.org/show_bug.cgi?id=171013
+ http://trac.webkit.org/changeset/215597
+
2017-04-20 Timothy Horton <[email protected]>
Expose obscured insets to web content (as "safe area insets")
Modified: trunk/LayoutTests/TestExpectations (215604 => 215605)
--- trunk/LayoutTests/TestExpectations 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/LayoutTests/TestExpectations 2017-04-21 06:04:20 UTC (rev 215605)
@@ -34,7 +34,6 @@
media/ios [ Skip ]
media/controls/ipad [ Skip ]
fast/text-autosizing [ Skip ]
-fast/css/variables/constants/ios [ Skip ]
# window.showModalDialog is only tested in DumpRenderTree on Mac.
editing/execCommand/show-modal-dialog-during-execCommand.html [ Skip ]
Modified: trunk/LayoutTests/platform/ios-wk2/TestExpectations (215604 => 215605)
--- trunk/LayoutTests/platform/ios-wk2/TestExpectations 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/LayoutTests/platform/ios-wk2/TestExpectations 2017-04-21 06:04:20 UTC (rev 215605)
@@ -14,7 +14,6 @@
scrollingcoordinator/ios [ Pass ]
tiled-drawing/ios [ Pass ]
editing/selection/character-granularity-rect.html [ Pass ]
-fast/css/variables/constants/ios [ Pass ]
fast/media/mq-inverted-colors-live-update.html [ Pass ]
fast/media/mq-inverted-colors-live-update-in-subframes.html [ Pass ]
Modified: trunk/Source/WebCore/CMakeLists.txt (215604 => 215605)
--- trunk/Source/WebCore/CMakeLists.txt 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/CMakeLists.txt 2017-04-21 06:04:20 UTC (rev 215605)
@@ -1453,7 +1453,6 @@
dom/Comment.cpp
dom/ComposedTreeIterator.cpp
dom/CompositionEvent.cpp
- dom/ConstantPropertyMap.cpp
dom/ContainerNode.cpp
dom/ContainerNodeAlgorithms.cpp
dom/ContextDestructionObserver.cpp
Modified: trunk/Source/WebCore/ChangeLog (215604 => 215605)
--- trunk/Source/WebCore/ChangeLog 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/ChangeLog 2017-04-21 06:04:20 UTC (rev 215605)
@@ -1,3 +1,18 @@
+2017-04-20 Commit Queue <[email protected]>
+
+ Unreviewed, rolling out r215597.
+ https://bugs.webkit.org/show_bug.cgi?id=171102
+
+ Made all tests crash under GuardMalloc (Requested by ap on
+ #webkit).
+
+ Reverted changeset:
+
+ "Expose obscured insets to web content (as "safe area
+ insets")"
+ https://bugs.webkit.org/show_bug.cgi?id=171013
+ http://trac.webkit.org/changeset/215597
+
2017-04-20 Dean Jackson <[email protected]>
Add Web Sharing to the features under consideration.
Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (215604 => 215605)
--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj 2017-04-21 06:04:20 UTC (rev 215605)
@@ -1258,8 +1258,6 @@
2D9BF7471DBFDC49007A7D99 /* MediaKeyMessageEvent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D9BF72F1DBFDC0F007A7D99 /* MediaKeyMessageEvent.cpp */; };
2D9BF74A1DBFDDFF007A7D99 /* JSMediaKeySessionCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2D9BF7481DBFDDF8007A7D99 /* JSMediaKeySessionCustom.cpp */; };
2D9F0E1314FF1CBF00BA0FF7 /* linearSRGB.icc in Resources */ = {isa = PBXBuildFile; fileRef = 2D9F0E1214FF1CBF00BA0FF7 /* linearSRGB.icc */; };
- 2DAF343C1EA7E0F100382CD3 /* ConstantPropertyMap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2DAF343A1EA7E0F100382CD3 /* ConstantPropertyMap.cpp */; };
- 2DAF343D1EA7E0F100382CD3 /* ConstantPropertyMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 2DAF343B1EA7E0F100382CD3 /* ConstantPropertyMap.h */; };
2DB9C4AA1B3231F40070F27F /* NSEventSPI.h in Headers */ = {isa = PBXBuildFile; fileRef = 2DB9C4A91B3231F40070F27F /* NSEventSPI.h */; settings = {ATTRIBUTES = (Private, ); }; };
2DC4CF791D2DD98900ECCC94 /* DataDetectorsUISPI.h in Headers */ = {isa = PBXBuildFile; fileRef = 2DC4CF781D2DD98900ECCC94 /* DataDetectorsUISPI.h */; settings = {ATTRIBUTES = (Private, ); }; };
2DCB837919F99BBA00A7FBE4 /* NSSharingServicePickerSPI.h in Headers */ = {isa = PBXBuildFile; fileRef = 2DCB837719F99BBA00A7FBE4 /* NSSharingServicePickerSPI.h */; settings = {ATTRIBUTES = (Private, ); }; };
@@ -8802,8 +8800,6 @@
2D9F0E1214FF1CBF00BA0FF7 /* linearSRGB.icc */ = {isa = PBXFileReference; lastKnownFileType = file; path = linearSRGB.icc; sourceTree = "<group>"; };
2DAAE32C19DCAF6000E002D2 /* MockPageOverlayClient.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MockPageOverlayClient.cpp; sourceTree = "<group>"; };
2DAAE32D19DCAF6000E002D2 /* MockPageOverlayClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MockPageOverlayClient.h; sourceTree = "<group>"; };
- 2DAF343A1EA7E0F100382CD3 /* ConstantPropertyMap.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ConstantPropertyMap.cpp; sourceTree = "<group>"; };
- 2DAF343B1EA7E0F100382CD3 /* ConstantPropertyMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ConstantPropertyMap.h; sourceTree = "<group>"; };
2DB9C4A91B3231F40070F27F /* NSEventSPI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSEventSPI.h; sourceTree = "<group>"; };
2DC4CF781D2DD98900ECCC94 /* DataDetectorsUISPI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DataDetectorsUISPI.h; sourceTree = "<group>"; };
2DCB837719F99BBA00A7FBE4 /* NSSharingServicePickerSPI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSSharingServicePickerSPI.h; sourceTree = "<group>"; };
@@ -25459,8 +25455,6 @@
79F2F59E1091939A000D87CB /* CompositionEvent.cpp */,
79F2F59F1091939A000D87CB /* CompositionEvent.h */,
79F2F5A01091939A000D87CB /* CompositionEvent.idl */,
- 2DAF343A1EA7E0F100382CD3 /* ConstantPropertyMap.cpp */,
- 2DAF343B1EA7E0F100382CD3 /* ConstantPropertyMap.h */,
A81872140977D3C0005826D9 /* ContainerNode.cpp */,
A81872110977D3C0005826D9 /* ContainerNode.h */,
A7A78CD41532BA62006C21E4 /* ContainerNodeAlgorithms.cpp */,
@@ -26493,7 +26487,6 @@
7C77C3D71DEF850A00A50BFA /* BlobLineEndings.h in Headers */,
E1C94AF9191303F000D5A893 /* BlobPart.h in Headers */,
7C77C3D11DEE472400A50BFA /* BlobPropertyBag.h in Headers */,
- 2DAF343D1EA7E0F100382CD3 /* ConstantPropertyMap.h in Headers */,
2EDEF1F5121B0EFC00726DB2 /* BlobRegistry.h in Headers */,
2EDEF1F7121B0EFC00726DB2 /* BlobRegistryImpl.h in Headers */,
2EB4BCD3121F03E300EC4885 /* BlobResourceHandle.h in Headers */,
@@ -31839,7 +31832,6 @@
E1E6EEA40B628DA8005F2F70 /* JSHTMLSelectElement.cpp in Sources */,
BC17F9660B64EBB8004A65CB /* JSHTMLSelectElementCustom.cpp in Sources */,
9B69D3B81B99100700E3512B /* JSHTMLSlotElement.cpp in Sources */,
- 2DAF343C1EA7E0F100382CD3 /* ConstantPropertyMap.cpp in Sources */,
E446143B0CD689CC00FADA75 /* JSHTMLSourceElement.cpp in Sources */,
9752D38D1413104B003305BD /* JSHTMLSpanElement.cpp in Sources */,
A80E7B0F0A19D606007FB8C5 /* JSHTMLStyleElement.cpp in Sources */,
Modified: trunk/Source/WebCore/css/CSSValueKeywords.in (215604 => 215605)
--- trunk/Source/WebCore/css/CSSValueKeywords.in 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/css/CSSValueKeywords.in 2017-04-21 06:04:20 UTC (rev 215605)
@@ -844,11 +844,6 @@
-internal-variable-value
//
-// UA Constants
-//
-constant
-
-//
// CSS_PROP_BREAK_BEFORE/AFTER/INSIDE
//
avoid-column
Modified: trunk/Source/WebCore/css/CSSVariableData.cpp (215604 => 215605)
--- trunk/Source/WebCore/css/CSSVariableData.cpp 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/css/CSSVariableData.cpp 2017-04-21 06:04:20 UTC (rev 215605)
@@ -101,7 +101,7 @@
bool CSSVariableData::checkVariablesForCyclesWithRange(CSSParserTokenRange range, CustomPropertyValueMap& customProperties, HashSet<AtomicString>& seenProperties, HashSet<AtomicString>& invalidProperties) const
{
while (!range.atEnd()) {
- if (range.peek().functionId() == CSSValueVar || range.peek().functionId() == CSSValueConstant) {
+ if (range.peek().functionId() == CSSValueVar) {
CSSParserTokenRange block = range.consumeBlock();
block.consumeWhitespace();
@@ -171,7 +171,7 @@
{
bool success = true;
while (!range.atEnd()) {
- if (range.peek().functionId() == CSSValueVar || range.peek().functionId() == CSSValueConstant)
+ if (range.peek().functionId() == CSSValueVar)
success &= resolveVariableReference(customProperties, range.consumeBlock(), result);
else
result.append(range.consume());
Modified: trunk/Source/WebCore/css/parser/CSSVariableParser.cpp (215604 => 215605)
--- trunk/Source/WebCore/css/parser/CSSVariableParser.cpp 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/css/parser/CSSVariableParser.cpp 2017-04-21 06:04:20 UTC (rev 215605)
@@ -49,13 +49,7 @@
return string.length() >= 2 && string[0] == '-' && string[1] == '-';
}
-static bool isValidConstantName(const CSSParserToken& token)
-{
- return token.type() == IdentToken;
-}
-
bool isValidVariableReference(CSSParserTokenRange, bool& hasAtApplyRule);
-bool isValidConstantReference(CSSParserTokenRange, bool& hasAtApplyRule);
static bool classifyBlock(CSSParserTokenRange range, bool& hasReferences, bool& hasAtApplyRule, bool isTopLevelBlock = true)
{
@@ -69,12 +63,6 @@
hasReferences = true;
continue;
}
- if (token.functionId() == CSSValueConstant) {
- if (!isValidConstantReference(block, hasAtApplyRule))
- return false; // Bail if any references are invalid
- hasReferences = true;
- continue;
- }
if (!classifyBlock(block, hasReferences, hasAtApplyRule, false))
return false;
continue;
@@ -134,23 +122,6 @@
return classifyBlock(range, hasReferences, hasAtApplyRule);
}
-bool isValidConstantReference(CSSParserTokenRange range, bool& hasAtApplyRule)
-{
- range.consumeWhitespace();
- if (!isValidConstantName(range.consumeIncludingWhitespace()))
- return false;
- if (range.atEnd())
- return true;
-
- if (range.consume().type() != CommaToken)
- return false;
- if (range.atEnd())
- return false;
-
- bool hasReferences = false;
- return classifyBlock(range, hasReferences, hasAtApplyRule);
-}
-
static CSSValueID classifyVariableRange(CSSParserTokenRange range, bool& hasReferences, bool& hasAtApplyRule)
{
hasReferences = false;
Deleted: trunk/Source/WebCore/dom/ConstantPropertyMap.cpp (215604 => 215605)
--- trunk/Source/WebCore/dom/ConstantPropertyMap.cpp 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/dom/ConstantPropertyMap.cpp 2017-04-21 06:04:20 UTC (rev 215605)
@@ -1,114 +0,0 @@
-/*
- * Copyright (C) 2017 Apple Inc. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- */
-
-#include "config.h"
-#include "ConstantPropertyMap.h"
-
-#include "CSSCustomPropertyValue.h"
-#include "CSSParserTokenRange.h"
-#include "CSSVariableData.h"
-#include "Document.h"
-#include "Page.h"
-#include <wtf/NeverDestroyed.h>
-
-namespace WebCore {
-
-ConstantPropertyMap::ConstantPropertyMap(Document& document)
- : m_document(document)
-{
-}
-
-const ConstantPropertyMap::Values& ConstantPropertyMap::values() const
-{
- if (!m_values)
- const_cast<ConstantPropertyMap&>(*this).buildValues();
- return *m_values;
-}
-
-const AtomicString& ConstantPropertyMap::nameForProperty(ConstantProperty property) const
-{
- static NeverDestroyed<AtomicString> safeAreaInsetTopName("safe-area-inset-top", AtomicString::ConstructFromLiteral);
- static NeverDestroyed<AtomicString> safeAreaInsetRightName("safe-area-inset-right", AtomicString::ConstructFromLiteral);
- static NeverDestroyed<AtomicString> safeAreaInsetBottomName("safe-area-inset-bottom", AtomicString::ConstructFromLiteral);
- static NeverDestroyed<AtomicString> safeAreaInsetLeftName("safe-area-inset-left", AtomicString::ConstructFromLiteral);
-
- switch (property) {
- case ConstantProperty::SafeAreaInsetTop:
- return safeAreaInsetTopName;
- case ConstantProperty::SafeAreaInsetRight:
- return safeAreaInsetRightName;
- case ConstantProperty::SafeAreaInsetBottom:
- return safeAreaInsetBottomName;
- case ConstantProperty::SafeAreaInsetLeft:
- return safeAreaInsetLeftName;
- }
-
- return nullAtom;
-}
-
-void ConstantPropertyMap::setValueForProperty(ConstantProperty property, Ref<CSSVariableData>&& data)
-{
- if (!m_values)
- buildValues();
-
- auto& name = nameForProperty(property);
- m_values->set(name, CSSCustomPropertyValue::createWithVariableData(name, WTFMove(data)));
-}
-
-void ConstantPropertyMap::buildValues()
-{
- m_values = Values { };
-
- updateConstantsForObscuredInsets();
-}
-
-static Ref<CSSVariableData> variableDataForPositivePixelLength(float lengthInPx)
-{
- ASSERT(lengthInPx >= 0);
-
- CSSParserToken token(NumberToken, lengthInPx, NumberValueType, NoSign);
- token.convertToDimensionWithUnit("px");
-
- CSSParserTokenRange tokenRange(Vector<CSSParserToken> { token });
- return CSSVariableData::create(tokenRange, false);
-}
-
-void ConstantPropertyMap::updateConstantsForObscuredInsets()
-{
- FloatBoxExtent obscuredInsets = m_document.page() ? m_document.page()->obscuredInsets() : FloatBoxExtent();
- setValueForProperty(ConstantProperty::SafeAreaInsetTop, variableDataForPositivePixelLength(obscuredInsets.top()));
- setValueForProperty(ConstantProperty::SafeAreaInsetRight, variableDataForPositivePixelLength(obscuredInsets.right()));
- setValueForProperty(ConstantProperty::SafeAreaInsetBottom, variableDataForPositivePixelLength(obscuredInsets.bottom()));
- setValueForProperty(ConstantProperty::SafeAreaInsetLeft, variableDataForPositivePixelLength(obscuredInsets.left()));
-}
-
-void ConstantPropertyMap::didChangeObscuredInsets()
-{
- updateConstantsForObscuredInsets();
- m_document.invalidateMatchedPropertiesCacheAndForceStyleRecalc();
-}
-
-}
Deleted: trunk/Source/WebCore/dom/ConstantPropertyMap.h (215604 => 215605)
--- trunk/Source/WebCore/dom/ConstantPropertyMap.h 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/dom/ConstantPropertyMap.h 2017-04-21 06:04:20 UTC (rev 215605)
@@ -1,69 +0,0 @@
-/*
- * Copyright (C) 2017 Apple Inc. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- */
-
-#pragma once
-
-#include <wtf/HashMap.h>
-#include <wtf/Ref.h>
-#include <wtf/text/AtomicString.h>
-#include <wtf/text/AtomicStringHash.h>
-
-namespace WebCore {
-
-class CSSCustomPropertyValue;
-class CSSVariableData;
-class Document;
-
-enum class ConstantProperty {
- SafeAreaInsetTop,
- SafeAreaInsetRight,
- SafeAreaInsetBottom,
- SafeAreaInsetLeft,
-};
-
-class ConstantPropertyMap {
-public:
- explicit ConstantPropertyMap(Document&);
-
- typedef HashMap<AtomicString, Ref<CSSCustomPropertyValue>> Values;
- const Values& values() const;
-
- void didChangeObscuredInsets();
-
-private:
- void buildValues();
-
- const AtomicString& nameForProperty(ConstantProperty) const;
- void setValueForProperty(ConstantProperty, Ref<CSSVariableData>&&);
-
- void updateConstantsForObscuredInsets();
-
- std::optional<Values> m_values;
-
- Document& m_document;
-};
-
-} // namespace WebCore
Modified: trunk/Source/WebCore/dom/Document.cpp (215604 => 215605)
--- trunk/Source/WebCore/dom/Document.cpp 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/dom/Document.cpp 2017-04-21 06:04:20 UTC (rev 215605)
@@ -43,7 +43,6 @@
#include "Comment.h"
#include "CommonVM.h"
#include "CompositionEvent.h"
-#include "ConstantPropertyMap.h"
#include "ContentSecurityPolicy.h"
#include "CookieJar.h"
#include "CustomElementReactionQueue.h"
@@ -453,7 +452,6 @@
, m_scriptRunner(std::make_unique<ScriptRunner>(*this))
, m_moduleLoader(std::make_unique<ScriptModuleLoader>(*this))
, m_xmlVersion(ASCIILiteral("1.0"))
- , m_constantPropertyMap(std::make_unique<ConstantPropertyMap>(*this))
, m_documentClasses(documentClasses)
, m_eventQueue(*this)
, m_weakFactory(this)
@@ -2052,11 +2050,6 @@
void Document::fontsNeedUpdate(FontSelector&)
{
- invalidateMatchedPropertiesCacheAndForceStyleRecalc();
-}
-
-void Document::invalidateMatchedPropertiesCacheAndForceStyleRecalc()
-{
if (auto* resolver = styleScope().resolverIfExists())
resolver->invalidateMatchedPropertiesCache();
if (pageCacheState() != NotInPageCache || !renderView())
Modified: trunk/Source/WebCore/dom/Document.h (215604 => 215605)
--- trunk/Source/WebCore/dom/Document.h 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/dom/Document.h 2017-04-21 06:04:20 UTC (rev 215605)
@@ -73,7 +73,6 @@
class AXObjectCache;
class Attr;
class CDATASection;
-class CSSCustomPropertyValue;
class CSSFontSelector;
class CSSStyleDeclaration;
class CSSStyleSheet;
@@ -84,7 +83,6 @@
class CanvasRenderingContext;
class CharacterData;
class Comment;
-class ConstantPropertyMap;
class DOMImplementation;
class DOMNamedFlowCollection;
class DOMSelection;
@@ -1208,8 +1206,6 @@
DocumentSharedObjectPool* sharedObjectPool() { return m_sharedObjectPool.get(); }
- void invalidateMatchedPropertiesCacheAndForceStyleRecalc();
-
void didRemoveAllPendingStylesheet();
void didClearStyleResolver();
@@ -1303,8 +1299,6 @@
void attachToCachedFrame(CachedFrameBase&);
void detachFromCachedFrame(CachedFrameBase&);
- ConstantPropertyMap& constantProperties() const { return *m_constantPropertyMap; }
-
protected:
enum ConstructionFlags { Synthesized = 1, NonRenderedPlaceholder = 1 << 1 };
Document(Frame*, const URL&, unsigned = DefaultDocumentClass, unsigned constructionFlags = 0);
@@ -1541,8 +1535,6 @@
DocumentOrderedMap m_imagesByUsemap;
- std::unique_ptr<ConstantPropertyMap> m_constantPropertyMap;
-
std::unique_ptr<SelectorQueryCache> m_selectorQueryCache;
DocumentClassFlags m_documentClasses;
Modified: trunk/Source/WebCore/page/Page.cpp (215604 => 215605)
--- trunk/Source/WebCore/page/Page.cpp 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/page/Page.cpp 2017-04-21 06:04:20 UTC (rev 215605)
@@ -29,7 +29,6 @@
#include "Chrome.h"
#include "ChromeClient.h"
#include "ClientRectList.h"
-#include "ConstantPropertyMap.h"
#include "ContextMenuClient.h"
#include "ContextMenuController.h"
#include "DatabaseProvider.h"
@@ -2290,20 +2289,6 @@
LOG(Layout, "hasMediaQueriesAffectedByAccessibilitySettingsChange, enqueueing style recalc");
}
-void Page::setObscuredInsets(const FloatBoxExtent& insets)
-{
- if (m_obscuredInsets == insets)
- return;
-
- m_obscuredInsets = insets;
-
- for (Frame* frame = &mainFrame(); frame; frame = frame->tree().traverseNext()) {
- if (!frame->document())
- continue;
- frame->document()->constantProperties().didChangeObscuredInsets();
- }
-}
-
#if ENABLE(DATA_INTERACTION)
bool Page::hasSelectionAtPosition(const FloatPoint& position) const
Modified: trunk/Source/WebCore/page/Page.h (215604 => 215605)
--- trunk/Source/WebCore/page/Page.h 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/page/Page.h 2017-04-21 06:04:20 UTC (rev 215605)
@@ -329,10 +329,10 @@
float topContentInset() const { return m_topContentInset; }
WEBCORE_EXPORT void setTopContentInset(float);
+#if PLATFORM(IOS)
const FloatBoxExtent& obscuredInsets() const { return m_obscuredInsets; }
- WEBCORE_EXPORT void setObscuredInsets(const FloatBoxExtent&);
-
-#if PLATFORM(IOS)
+ void setObscuredInsets(FloatBoxExtent insets) { m_obscuredInsets = insets; }
+
bool enclosedInScrollableAncestorView() const { return m_enclosedInScrollableAncestorView; }
void setEnclosedInScrollableAncestorView(bool f) { m_enclosedInScrollableAncestorView = f; }
#endif
@@ -686,9 +686,10 @@
float m_viewScaleFactor { 1 };
float m_topContentInset;
- FloatBoxExtent m_obscuredInsets;
#if PLATFORM(IOS)
+ // This is only used for history scroll position restoration.
+ FloatBoxExtent m_obscuredInsets;
bool m_enclosedInScrollableAncestorView { false };
#endif
Modified: trunk/Source/WebCore/style/StyleResolveForDocument.cpp (215604 => 215605)
--- trunk/Source/WebCore/style/StyleResolveForDocument.cpp 2017-04-21 05:36:11 UTC (rev 215604)
+++ trunk/Source/WebCore/style/StyleResolveForDocument.cpp 2017-04-21 06:04:20 UTC (rev 215605)
@@ -30,7 +30,6 @@
#include "StyleResolveForDocument.h"
#include "CSSFontSelector.h"
-#include "ConstantPropertyMap.h"
#include "Document.h"
#include "Frame.h"
#include "FrameView.h"
@@ -125,9 +124,6 @@
documentStyle.fontCascade().update(&const_cast<Document&>(document).fontSelector());
- for (auto& it : document.constantProperties().values())
- documentStyle.setCustomPropertyValue(it.key, makeRef(it.value.get()));
-
return documentStyle;
}