Diff
Modified: trunk/Source/WebCore/ChangeLog (143862 => 143863)
--- trunk/Source/WebCore/ChangeLog 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/ChangeLog 2013-02-24 13:01:06 UTC (rev 143863)
@@ -1,3 +1,45 @@
+2013-02-24 Andreas Kling <[email protected]>
+
+ Reduce include graph of JSDOMBinding.h
+ <http://webkit.org/b/110709>
+
+ Reviewed by Antti Koivisto.
+
+ Move WebCore::root(Foo*) to the custom JSFooCustom.h headers.
+ This reduces the number of headers pulled in by JSDOMBinding.h.
+
+ * WebCore.xcodeproj/project.pbxproj:
+ * bindings/js/JSCSSRuleCustom.cpp:
+ * bindings/js/JSCSSRuleCustom.h: Added.
+ (WebCore::root):
+ * bindings/js/JSCSSRuleListCustom.cpp:
+ * bindings/js/JSCSSStyleDeclarationCustom.h:
+ (WebCore::root):
+ * bindings/js/JSDOMBinding.h:
+ * bindings/js/JSMediaListCustom.h: Added.
+ (WebCore::root):
+ * bindings/js/JSMutationObserverCustom.cpp:
+ * bindings/js/JSNodeCustom.h:
+ (WebCore::root):
+ * bindings/js/JSSVGElementInstanceCustom.cpp:
+ * bindings/js/JSStyleSheetCustom.h: Added.
+ (WebCore::root):
+ * bindings/js/JSTextTrackCustom.h:
+ * bindings/js/JSTextTrackListCustom.cpp:
+ * bindings/js/JSXPathResultCustom.cpp:
+ * bindings/js/SerializedScriptValue.cpp:
+ * bindings/scripts/CodeGeneratorGObject.pm:
+ (Generate):
+ * bindings/scripts/CodeGeneratorJS.pm:
+ (GenerateImplementation):
+ * bindings/scripts/CodeGeneratorObjC.pm:
+ (AddIncludesForType):
+ * css/CSSRule.idl:
+ * css/CSSStyleDeclaration.idl:
+ * css/MediaList.idl:
+ * css/StyleSheet.idl:
+ * editing/mac/EditorMac.mm:
+
2013-02-23 Alexey Proskuryakov <[email protected]>
ResourceRequestBase unnecessarily updates when nothing changes
Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (143862 => 143863)
--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj 2013-02-24 13:01:06 UTC (rev 143863)
@@ -4706,6 +4706,9 @@
AD4495F4141FC08900541EDF /* EventListenerMap.h in Headers */ = {isa = PBXBuildFile; fileRef = AD4495F2141FC08900541EDF /* EventListenerMap.h */; settings = {ATTRIBUTES = (Private, ); }; };
AD6E71AC1668899D00320C13 /* DocumentSharedObjectPool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = AD6E71AA1668899D00320C13 /* DocumentSharedObjectPool.cpp */; };
AD6E71AD1668899D00320C13 /* DocumentSharedObjectPool.h in Headers */ = {isa = PBXBuildFile; fileRef = AD6E71AB1668899D00320C13 /* DocumentSharedObjectPool.h */; };
+ AD726FED16DA1171003A4E6D /* JSCSSStyleDeclarationCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = AD726FEA16D9F40B003A4E6D /* JSCSSStyleDeclarationCustom.h */; settings = {ATTRIBUTES = (Private, ); }; };
+ AD726FEE16DA11BC003A4E6D /* JSStyleSheetCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = AD726FEC16D9F4B9003A4E6D /* JSStyleSheetCustom.h */; settings = {ATTRIBUTES = (Private, ); }; };
+ AD726FEF16DA11F5003A4E6D /* JSCSSRuleCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = AD726FE916D9F40A003A4E6D /* JSCSSRuleCustom.h */; settings = {ATTRIBUTES = (Private, ); }; };
ADDF1AD71257CD9A0003A759 /* RenderSVGPath.h in Headers */ = {isa = PBXBuildFile; fileRef = ADDF1AD51257CD9A0003A759 /* RenderSVGPath.h */; };
B10B6980140C174000BC1C26 /* WebVTTToken.h in Headers */ = {isa = PBXBuildFile; fileRef = B10B697D140C174000BC1C26 /* WebVTTToken.h */; };
B10B6981140C174000BC1C26 /* WebVTTTokenizer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B10B697E140C174000BC1C26 /* WebVTTTokenizer.cpp */; };
@@ -12114,6 +12117,10 @@
AD4495F2141FC08900541EDF /* EventListenerMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EventListenerMap.h; sourceTree = "<group>"; };
AD6E71AA1668899D00320C13 /* DocumentSharedObjectPool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DocumentSharedObjectPool.cpp; sourceTree = "<group>"; };
AD6E71AB1668899D00320C13 /* DocumentSharedObjectPool.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DocumentSharedObjectPool.h; sourceTree = "<group>"; };
+ AD726FE716D9F204003A4E6D /* JSMediaListCustom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSMediaListCustom.h; sourceTree = "<group>"; };
+ AD726FE916D9F40A003A4E6D /* JSCSSRuleCustom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSCSSRuleCustom.h; sourceTree = "<group>"; };
+ AD726FEA16D9F40B003A4E6D /* JSCSSStyleDeclarationCustom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSCSSStyleDeclarationCustom.h; sourceTree = "<group>"; };
+ AD726FEC16D9F4B9003A4E6D /* JSStyleSheetCustom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSStyleSheetCustom.h; sourceTree = "<group>"; };
ADDF1AD41257CD9A0003A759 /* RenderSVGPath.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RenderSVGPath.cpp; sourceTree = "<group>"; };
ADDF1AD51257CD9A0003A759 /* RenderSVGPath.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RenderSVGPath.h; sourceTree = "<group>"; };
B10B697D140C174000BC1C26 /* WebVTTToken.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebVTTToken.h; sourceTree = "<group>"; };
@@ -21086,6 +21093,9 @@
BC4EDEF70C08F414007EDD49 /* Custom */ = {
isa = PBXGroup;
children = (
+ AD726FEC16D9F4B9003A4E6D /* JSStyleSheetCustom.h */,
+ AD726FE916D9F40A003A4E6D /* JSCSSRuleCustom.h */,
+ AD726FEA16D9F40B003A4E6D /* JSCSSStyleDeclarationCustom.h */,
BC275CB211C5E85C00C9206C /* JSArrayBufferCustom.cpp */,
86243D0011BC31F700CC006A /* JSArrayBufferViewHelper.h */,
BC2ED6BB0C6BD2F000920BFF /* JSAttrCustom.cpp */,
@@ -21166,6 +21176,7 @@
1C5FAEE60DCFDA6800D58F78 /* JSJavaScriptCallFrameCustom.cpp */,
BCE1C43F0D9830F4003B02F2 /* JSLocationCustom.cpp */,
1464E06B135EC10600FDB00A /* JSMediaListCustom.cpp */,
+ AD726FE716D9F204003A4E6D /* JSMediaListCustom.h */,
9FDC8FF112FAB0060099AB1C /* JSMemoryInfoCustom.cpp */,
E1A5F99A0E7EAA2500AF85EA /* JSMessageChannelCustom.cpp */,
410B7E711045FAB000D8224F /* JSMessageEventCustom.cpp */,
@@ -23200,16 +23211,19 @@
29A8122E0FBB9C1D00510293 /* AccessibilityARIAGridCell.h in Headers */,
29A812330FBB9C1D00510293 /* AccessibilityARIAGridRow.h in Headers */,
29A8123B0FBB9C1D00510293 /* AccessibilityImageMapLink.h in Headers */,
+ AD726FEE16DA11BC003A4E6D /* JSStyleSheetCustom.h in Headers */,
29A8122C0FBB9C1D00510293 /* AccessibilityList.h in Headers */,
29A812430FBB9C1D00510293 /* AccessibilityListBox.h in Headers */,
29A812420FBB9C1D00510293 /* AccessibilityListBoxOption.h in Headers */,
07B0113F1032242200FBDC33 /* AccessibilityMediaControls.h in Headers */,
76CDD2F31103DA6600680521 /* AccessibilityMenuList.h in Headers */,
76CDD2F71103DA6600680521 /* AccessibilityMenuListOption.h in Headers */,
+ AD726FED16DA1171003A4E6D /* JSCSSStyleDeclarationCustom.h in Headers */,
76CDD2F51103DA6600680521 /* AccessibilityMenuListPopup.h in Headers */,
29ACB212143E7128006BCA5F /* AccessibilityMockObject.h in Headers */,
29A812360FBB9C1D00510293 /* AccessibilityObject.h in Headers */,
A409C985116D0DDD007197BD /* AccessibilityProgressIndicator.h in Headers */,
+ AD726FEF16DA11F5003A4E6D /* JSCSSRuleCustom.h in Headers */,
29A812390FBB9C1D00510293 /* AccessibilityRenderObject.h in Headers */,
93C4F6EB1108F9A50099D0DB /* AccessibilityScrollbar.h in Headers */,
29489FC712C00F0300D83F0F /* AccessibilityScrollView.h in Headers */,
Modified: trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -42,6 +42,7 @@
#include "JSCSSStyleRule.h"
#include "JSCSSSupportsRule.h"
#include "JSNode.h"
+#include "JSStyleSheetCustom.h"
#include "JSWebKitCSSFilterRule.h"
#include "JSWebKitCSSKeyframeRule.h"
#include "JSWebKitCSSKeyframesRule.h"
Copied: trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.h (from rev 143862, trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp) (0 => 143863)
--- trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.h (rev 0)
+++ trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.h 2013-02-24 13:01:06 UTC (rev 143863)
@@ -0,0 +1,47 @@
+/*
+ * Copyright (C) 2013 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 COMPUTER, 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 COMPUTER, 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.
+ */
+
+#ifndef JSCSSRuleCustom_h
+#define JSCSSRuleCustom_h
+
+#include "CSSRule.h"
+#include "CSSStyleSheet.h"
+
+namespace WebCore {
+
+void* root(StyleSheet*);
+
+inline void* root(CSSRule* rule)
+{
+ if (rule->parentRule())
+ return root(rule->parentRule());
+ if (rule->parentStyleSheet())
+ return root(rule->parentStyleSheet());
+ return rule;
+}
+
+} // namespace WebCore
+
+#endif // JSCSSRuleCustom_h
Modified: trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -29,7 +29,8 @@
#include "CSSRule.h"
#include "CSSRuleList.h"
#include "CSSStyleSheet.h"
-#include "JSNode.h"
+#include "JSCSSRuleCustom.h"
+#include "JSStyleSheetCustom.h"
using namespace JSC;
Modified: trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.h (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.h 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.h 2013-02-24 13:01:06 UTC (rev 143863)
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2008 Apple Inc. All Rights Reserved.
+ * Copyright (C) 2008, 2013 Apple Inc. All Rights Reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,6 +26,23 @@
#ifndef JSCSSStyleDeclarationCustom_h
#define JSCSSStyleDeclarationCustom_h
+#include "CSSRule.h"
+#include "CSSStyleDeclaration.h"
+#include "CSSStyleSheet.h"
#include "JSCSSStyleDeclaration.h"
+#include "JSStyleSheetCustom.h"
+namespace WebCore {
+
+inline void* root(CSSStyleDeclaration* style)
+{
+ if (CSSRule* parentRule = style->parentRule())
+ return root(parentRule);
+ if (CSSStyleSheet* styleSheet = style->parentStyleSheet())
+ return root(styleSheet);
+ return style;
+}
+
+}
+
#endif // JSCSSStyleDeclarationCustom_h
Modified: trunk/Source/WebCore/bindings/js/JSDOMBinding.h (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSDOMBinding.h 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSDOMBinding.h 2013-02-24 13:01:06 UTC (rev 143863)
@@ -1,6 +1,6 @@
/*
* Copyright (C) 1999-2001 Harri Porten ([email protected])
- * Copyright (C) 2003, 2004, 2005, 2006, 2008, 2009 Apple Inc. All rights reserved.
+ * Copyright (C) 2003, 2004, 2005, 2006, 2008, 2009, 2013 Apple Inc. All rights reserved.
* Copyright (C) 2007 Samuel Weinig <[email protected]>
* Copyright (C) 2009 Google, Inc. All rights reserved.
* Copyright (C) 2012 Ericsson AB. All rights reserved.
@@ -24,18 +24,11 @@
#define JSDOMBinding_h
#include "BindingState.h"
-#include "CSSImportRule.h"
-#include "CSSStyleDeclaration.h"
-#include "CSSStyleSheet.h"
#include "JSDOMGlobalObject.h"
#include "JSDOMWrapper.h"
#include "DOMWrapperWorld.h"
#include "Document.h"
-#include "Element.h"
-#include "MediaList.h"
#include "ScriptWrappable.h"
-#include "StylePropertySet.h"
-#include "StyledElement.h"
#include <heap/SlotVisitor.h>
#include <heap/Weak.h>
#include <runtime/Error.h>
@@ -206,54 +199,6 @@
return createWrapper<WrapperClass>(exec, globalObject, domObject);
}
- inline void* root(Node* node)
- {
- if (node->inDocument())
- return node->document();
-
- while (node->parentOrShadowHostNode())
- node = node->parentOrShadowHostNode();
- return node;
- }
-
- inline void* root(StyleSheet*);
-
- inline void* root(CSSRule* rule)
- {
- if (rule->parentRule())
- return root(rule->parentRule());
- if (rule->parentStyleSheet())
- return root(rule->parentStyleSheet());
- return rule;
- }
-
- inline void* root(StyleSheet* styleSheet)
- {
- if (styleSheet->ownerRule())
- return root(styleSheet->ownerRule());
- if (styleSheet->ownerNode())
- return root(styleSheet->ownerNode());
- return styleSheet;
- }
-
- inline void* root(CSSStyleDeclaration* style)
- {
- if (CSSRule* parentRule = style->parentRule())
- return root(parentRule);
- if (CSSStyleSheet* styleSheet = style->parentStyleSheet())
- return root(styleSheet);
- return style;
- }
-
- inline void* root(MediaList* mediaList)
- {
- if (CSSRule* parentRule = mediaList->parentRule())
- return root(parentRule);
- if (CSSStyleSheet* parentStyleSheet = mediaList->parentStyleSheet())
- return root(parentStyleSheet);
- return mediaList;
- }
-
inline JSC::JSValue argumentOrNull(JSC::ExecState* exec, unsigned index)
{
return index >= exec->argumentCount() ? JSC::JSValue() : exec->argument(index);
Copied: trunk/Source/WebCore/bindings/js/JSMediaListCustom.h (from rev 143862, trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp) (0 => 143863)
--- trunk/Source/WebCore/bindings/js/JSMediaListCustom.h (rev 0)
+++ trunk/Source/WebCore/bindings/js/JSMediaListCustom.h 2013-02-24 13:01:06 UTC (rev 143863)
@@ -0,0 +1,48 @@
+/*
+ * Copyright (C) 2013 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 COMPUTER, 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 COMPUTER, 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.
+ */
+
+#ifndef JSMediaListCustom_h
+#define JSMediaListCustom_h
+
+#include "CSSRule.h"
+#include "CSSStyleSheet.h"
+#include "JSCSSRuleCustom.h"
+#include "JSStyleSheetCustom.h"
+#include "MediaList.h"
+
+namespace WebCore {
+
+inline void* root(MediaList* mediaList)
+{
+ if (CSSRule* parentRule = mediaList->parentRule())
+ return root(parentRule);
+ if (CSSStyleSheet* parentStyleSheet = mediaList->parentStyleSheet())
+ return root(parentStyleSheet);
+ return mediaList;
+}
+
+} // namespace WebCore
+
+#endif // JSMediaListCustom_h
Modified: trunk/Source/WebCore/bindings/js/JSMutationObserverCustom.cpp (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSMutationObserverCustom.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSMutationObserverCustom.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -32,7 +32,9 @@
#include "JSMutationObserver.h"
+#include "ExceptionCode.h"
#include "JSMutationCallback.h"
+#include "JSNodeCustom.h"
#include "MutationObserver.h"
#include <runtime/Error.h>
#include <runtime/PrivateName.h>
Modified: trunk/Source/WebCore/bindings/js/JSNodeCustom.h (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSNodeCustom.h 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSNodeCustom.h 2013-02-24 13:01:06 UTC (rev 143863)
@@ -27,8 +27,8 @@
#define JSNodeCustom_h
#include "JSDOMBinding.h"
+#include "JSNode.h"
#include "ScriptState.h"
-#include <wtf/AlwaysInline.h>
namespace WebCore {
@@ -62,6 +62,16 @@
willCreatePossiblyOrphanedTreeByRemovalSlowCase(root);
}
+inline void* root(Node* node)
+{
+ if (node->inDocument())
+ return node->document();
+
+ while (node->parentOrShadowHostNode())
+ node = node->parentOrShadowHostNode();
+ return node;
+}
+
} // namespace WebCore
#endif // JSDOMNodeCustom_h
Modified: trunk/Source/WebCore/bindings/js/JSSVGElementInstanceCustom.cpp (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSSVGElementInstanceCustom.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSSVGElementInstanceCustom.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -31,6 +31,7 @@
#include "JSSVGElementInstance.h"
#include "JSEventTarget.h"
+#include "JSNodeCustom.h"
namespace WebCore {
Copied: trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.h (from rev 143862, trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp) (0 => 143863)
--- trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.h (rev 0)
+++ trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.h 2013-02-24 13:01:06 UTC (rev 143863)
@@ -0,0 +1,47 @@
+/*
+ * Copyright (C) 2013 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 COMPUTER, 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 COMPUTER, 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.
+ */
+
+#ifndef JSStyleSheetCustom_h
+#define JSStyleSheetCustom_h
+
+#include "CSSImportRule.h"
+#include "CSSStyleSheet.h"
+#include "JSCSSRuleCustom.h"
+#include "JSNodeCustom.h"
+
+namespace WebCore {
+
+inline void* root(StyleSheet* styleSheet)
+{
+ if (CSSImportRule* ownerRule = styleSheet->ownerRule())
+ return root(ownerRule);
+ if (Node* ownerNode = styleSheet->ownerNode())
+ return root(ownerNode);
+ return styleSheet;
+}
+
+} // namespace WebCore
+
+#endif // JSStyleSheetCustom_h
Modified: trunk/Source/WebCore/bindings/js/JSTextTrackCustom.h (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSTextTrackCustom.h 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSTextTrackCustom.h 2013-02-24 13:01:06 UTC (rev 143863)
@@ -31,6 +31,7 @@
#include "HTMLMediaElement.h"
#include "HTMLTrackElement.h"
+#include "JSNodeCustom.h"
#include "LoadableTextTrack.h"
using namespace JSC;
Modified: trunk/Source/WebCore/bindings/js/JSTextTrackListCustom.cpp (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSTextTrackListCustom.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSTextTrackListCustom.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -29,6 +29,7 @@
#include "JSTextTrackList.h"
#include "HTMLMediaElement.h"
+#include "JSNodeCustom.h"
using namespace JSC;
Modified: trunk/Source/WebCore/bindings/js/JSXPathResultCustom.cpp (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/JSXPathResultCustom.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/JSXPathResultCustom.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -27,6 +27,7 @@
#include "JSXPathResult.h"
#include "JSDOMBinding.h"
+#include "JSNodeCustom.h"
#include "XPathResult.h"
#include "XPathValue.h"
Modified: trunk/Source/WebCore/bindings/js/SerializedScriptValue.cpp (143862 => 143863)
--- trunk/Source/WebCore/bindings/js/SerializedScriptValue.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/js/SerializedScriptValue.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -28,6 +28,7 @@
#include "SerializedScriptValue.h"
#include "Blob.h"
+#include "ExceptionCode.h"
#include "File.h"
#include "FileList.h"
#include "ImageData.h"
Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorGObject.pm (143862 => 143863)
--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorGObject.pm 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorGObject.pm 2013-02-24 13:01:06 UTC (rev 143863)
@@ -1382,6 +1382,7 @@
$implIncludes{"${className}Private.h"} = 1;
$implIncludes{"JSMainThreadExecState.h"} = 1;
$implIncludes{"ExceptionCode.h"} = 1;
+ $implIncludes{"CSSImportRule.h"} = 1;
$hdrIncludes{"webkitdom/${parentClassName}.h"} = 1;
Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (143862 => 143863)
--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm 2013-02-24 13:01:06 UTC (rev 143863)
@@ -2512,6 +2512,8 @@
$rootString .= " if (!root)\n";
$rootString .= " return false;\n";
} elsif (GetGenerateIsReachable($interface) eq "ImplElementRoot") {
+ $implIncludes{"Element.h"} = 1;
+ $implIncludes{"JSNodeCustom.h"} = 1;
$rootString = " Element* element = js${interfaceName}->impl()->element();\n";
$rootString .= " if (!element)\n";
$rootString .= " return false;\n";
@@ -2519,6 +2521,8 @@
} elsif ($interfaceName eq "CanvasRenderingContext") {
$rootString = " void* root = WebCore::root(js${interfaceName}->impl()->canvas());\n";
} elsif (GetGenerateIsReachable($interface) eq "ImplOwnerNodeRoot") {
+ $implIncludes{"Element.h"} = 1;
+ $implIncludes{"JSNodeCustom.h"} = 1;
$rootString = " void* root = WebCore::root(js${interfaceName}->impl()->ownerNode());\n";
} else {
$rootString = " void* root = WebCore::root(js${interfaceName}->impl());\n";
Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorObjC.pm (143862 => 143863)
--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorObjC.pm 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorObjC.pm 2013-02-24 13:01:06 UTC (rev 143863)
@@ -620,6 +620,7 @@
}
# FIXME: won't compile without these
+ $implIncludes{"CSSImportRule.h"} = 1 if $type eq "CSSRule";
$implIncludes{"StylePropertySet.h"} = 1 if $type eq "CSSStyleDeclaration";
$implIncludes{"NameNodeList.h"} = 1 if $type eq "NodeList";
Modified: trunk/Source/WebCore/css/CSSRule.idl (143862 => 143863)
--- trunk/Source/WebCore/css/CSSRule.idl 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/css/CSSRule.idl 2013-02-24 13:01:06 UTC (rev 143863)
@@ -20,6 +20,7 @@
// Introduced in DOM Level 2:
[
+ JSCustomHeader,
JSCustomMarkFunction,
JSGenerateIsReachable,
CustomToJSObject,
Modified: trunk/Source/WebCore/css/CSSStyleDeclaration.idl (143862 => 143863)
--- trunk/Source/WebCore/css/CSSStyleDeclaration.idl 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/css/CSSStyleDeclaration.idl 2013-02-24 13:01:06 UTC (rev 143863)
@@ -20,6 +20,7 @@
// Introduced in DOM Level 2:
[
+ JSCustomHeader,
JSCustomMarkFunction,
JSGenerateIsReachable,
JSCustomGetOwnPropertySlotAndDescriptor,
Modified: trunk/Source/WebCore/css/MediaList.idl (143862 => 143863)
--- trunk/Source/WebCore/css/MediaList.idl 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/css/MediaList.idl 2013-02-24 13:01:06 UTC (rev 143863)
@@ -25,6 +25,7 @@
// Introduced in DOM Level 2:
[
+ JSCustomHeader,
JSGenerateIsReachable,
IndexedGetter,
ImplementationLacksVTable
Modified: trunk/Source/WebCore/css/StyleSheet.idl (143862 => 143863)
--- trunk/Source/WebCore/css/StyleSheet.idl 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/css/StyleSheet.idl 2013-02-24 13:01:06 UTC (rev 143863)
@@ -20,6 +20,7 @@
// Introduced in DOM Level 2:
[
+ JSCustomHeader,
JSCustomMarkFunction,
JSGenerateIsReachable,
CustomToJSObject,
Modified: trunk/Source/WebCore/editing/mac/EditorMac.mm (143862 => 143863)
--- trunk/Source/WebCore/editing/mac/EditorMac.mm 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebCore/editing/mac/EditorMac.mm 2013-02-24 13:01:06 UTC (rev 143863)
@@ -47,6 +47,7 @@
#import "RenderBlock.h"
#import "RuntimeApplicationChecks.h"
#import "Sound.h"
+#import "StylePropertySet.h"
#import "Text.h"
#import "TypingCommand.h"
#import "htmlediting.h"
Modified: trunk/Source/WebKit/mac/ChangeLog (143862 => 143863)
--- trunk/Source/WebKit/mac/ChangeLog 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebKit/mac/ChangeLog 2013-02-24 13:01:06 UTC (rev 143863)
@@ -1,3 +1,12 @@
+2013-02-24 Andreas Kling <[email protected]>
+
+ Reduce include graph of JSDOMBinding.h
+ <http://webkit.org/b/110709>
+
+ Reviewed by Antti Koivisto.
+
+ * WebView/WebHTMLView.mm:
+
2013-02-21 Grzegorz Czajkowski <[email protected]>
Allow to retrieve the request data from abstract TextCheckingRequest to be accessible for WK2
Modified: trunk/Source/WebKit/mac/WebView/WebHTMLView.mm (143862 => 143863)
--- trunk/Source/WebKit/mac/WebView/WebHTMLView.mm 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebKit/mac/WebView/WebHTMLView.mm 2013-02-24 13:01:06 UTC (rev 143863)
@@ -80,6 +80,7 @@
#import <WebCore/ColorMac.h>
#import <WebCore/ContextMenu.h>
#import <WebCore/ContextMenuController.h>
+#import <WebCore/CSSStyleDeclaration.h>
#import <WebCore/Document.h>
#import <WebCore/DocumentFragment.h>
#import <WebCore/DocumentMarkerController.h>
Modified: trunk/Source/WebKit2/ChangeLog (143862 => 143863)
--- trunk/Source/WebKit2/ChangeLog 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebKit2/ChangeLog 2013-02-24 13:01:06 UTC (rev 143863)
@@ -1,3 +1,14 @@
+2013-02-24 Andreas Kling <[email protected]>
+
+ Reduce include graph of JSDOMBinding.h
+ <http://webkit.org/b/110709>
+
+ Reviewed by Antti Koivisto.
+
+ * Shared/WebRenderObject.cpp:
+ (WebKit::WebRenderObject::WebRenderObject):
+ * WebProcess/Storage/StorageAreaProxy.cpp:
+
2013-02-22 Sam Weinig <[email protected]>
Add temporary work around for 32-bit plugins not working in production builds as XPCServices
Modified: trunk/Source/WebKit2/Shared/WebRenderObject.cpp (143862 => 143863)
--- trunk/Source/WebKit2/Shared/WebRenderObject.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebKit2/Shared/WebRenderObject.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -64,11 +64,10 @@
m_elementTagName = element->tagName();
m_elementID = element->getIdAttribute();
if (element->isStyledElement() && element->hasClass()) {
- StyledElement* styledElement = static_cast<StyledElement*>(element);
- if (size_t classNameCount = styledElement->classNames().size()) {
+ if (size_t classNameCount = element->classNames().size()) {
m_elementClassNames = MutableArray::create();
for (size_t i = 0; i < classNameCount; ++i)
- m_elementClassNames->append(WebString::create(styledElement->classNames()[i]).get());
+ m_elementClassNames->append(WebString::create(element->classNames()[i]).get());
}
}
}
Modified: trunk/Source/WebKit2/WebProcess/Storage/StorageAreaProxy.cpp (143862 => 143863)
--- trunk/Source/WebKit2/WebProcess/Storage/StorageAreaProxy.cpp 2013-02-24 08:39:36 UTC (rev 143862)
+++ trunk/Source/WebKit2/WebProcess/Storage/StorageAreaProxy.cpp 2013-02-24 13:01:06 UTC (rev 143863)
@@ -30,6 +30,7 @@
#include "StorageManagerMessages.h"
#include "StorageNamespaceProxy.h"
#include "WebProcess.h"
+#include <WebCore/ExceptionCode.h>
#include <WebCore/Frame.h>
#include <WebCore/Page.h>
#include <WebCore/SchemeRegistry.h>