Reviewed by Darin Adler.
https://bugs.webkit.org/show_bug.cgi?id=22337
Enable workers by default
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@38567 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog
index 1f85729..15fd517 100644
--- a/JavaScriptCore/ChangeLog
+++ b/JavaScriptCore/ChangeLog
@@ -1,5 +1,14 @@
2008-11-18 Alexey Proskuryakov <ap@webkit.org>
+ Reviewed by Darin Adler.
+
+ https://bugs.webkit.org/show_bug.cgi?id=22337
+ Enable workers by default
+
+ * Configurations/JavaScriptCore.xcconfig: Define ENABLE_WORKERS.
+
+2008-11-18 Alexey Proskuryakov <ap@webkit.org>
+
- Windows build fix
* wrec/WRECFunctors.h:
diff --git a/JavaScriptCore/Configurations/JavaScriptCore.xcconfig b/JavaScriptCore/Configurations/JavaScriptCore.xcconfig
index 8e3d3c0..c6592aa 100644
--- a/JavaScriptCore/Configurations/JavaScriptCore.xcconfig
+++ b/JavaScriptCore/Configurations/JavaScriptCore.xcconfig
@@ -13,7 +13,7 @@
PRODUCT_NAME = JavaScriptCore;
// This needs to be kept sorted, and in sync with FEATURE_DEFINES in WebCore.xcconfig, WebKit.xcconfig and the default settings of build-webkit.
-FEATURE_DEFINES = ENABLE_DATABASE ENABLE_DOM_STORAGE ENABLE_ICONDATABASE ENABLE_OFFLINE_WEB_APPLICATIONS ENABLE_SVG ENABLE_SVG_ANIMATION ENABLE_SVG_AS_IMAGE ENABLE_SVG_FONTS ENABLE_SVG_FOREIGN_OBJECT ENABLE_SVG_USE ENABLE_VIDEO ENABLE_XPATH ENABLE_XSLT;
+FEATURE_DEFINES = ENABLE_DATABASE ENABLE_DOM_STORAGE ENABLE_ICONDATABASE ENABLE_OFFLINE_WEB_APPLICATIONS ENABLE_SVG ENABLE_SVG_ANIMATION ENABLE_SVG_AS_IMAGE ENABLE_SVG_FONTS ENABLE_SVG_FOREIGN_OBJECT ENABLE_SVG_USE ENABLE_VIDEO ENABLE_WORKERS ENABLE_XPATH ENABLE_XSLT;
OTHER_CFLAGS = $(OTHER_CFLAGS_$(CONFIGURATION)_$(CURRENT_VARIANT));
OTHER_CFLAGS_Release_normal = -fomit-frame-pointer;
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 010a2c1..f73fe89 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,25 @@
+2008-11-18 Alexey Proskuryakov <ap@webkit.org>
+
+ Reviewed by Darin Adler.
+
+ https://bugs.webkit.org/show_bug.cgi?id=22337
+ Enable workers by default
+
+ Adding some tests.
+
+ * fast/workers: Added.
+ * fast/workers/resources: Added.
+ * fast/workers/resources/worker-common.js: Added.
+ * fast/workers/resources/worker-event-listener.js: Added.
+ * fast/workers/worker-constructor-expected.txt: Added.
+ * fast/workers/worker-constructor.html: Added.
+ * fast/workers/worker-event-listener-expected.txt: Added.
+ * fast/workers/worker-event-listener.html: Added.
+ * fast/workers/worker-gc-expected.txt: Added.
+ * fast/workers/worker-gc.html: Added.
+ * fast/workers/worker-location-expected.txt: Added.
+ * fast/workers/worker-location.html: Added.
+
2008-11-18 Darin Adler <darin@apple.com>
Reviewed by Alexey Proskuryakov.
diff --git a/LayoutTests/fast/workers/resources/worker-common.js b/LayoutTests/fast/workers/resources/worker-common.js
new file mode 100644
index 0000000..cfeabe2
--- /dev/null
+++ b/LayoutTests/fast/workers/resources/worker-common.js
@@ -0,0 +1,24 @@
+function gc()
+{
+ for (var i = 0; i < 10000; i++) { // > force garbage collection (FF requires about 9K allocations before a collect)
+ var s = new String("abc");
+ }
+}
+
+onmessage = function(evt)
+{
+ gc();
+
+ if (evt.data == "ping")
+ postMessage("pong");
+ else if (evt.data == "freeze")
+ while (1) {}
+ else if (/eval.+/.test(evt.data)) {
+ try {
+ postMessage(evt.data.substr(5) + ": " + eval(evt.data.substr(5)));
+ } catch (ex) {
+ postMessage(evt.data.substr(5) + ": " + ex);
+ }
+ }
+ gc();
+}
diff --git a/LayoutTests/fast/workers/resources/worker-event-listener.js b/LayoutTests/fast/workers/resources/worker-event-listener.js
new file mode 100644
index 0000000..206fd99
--- /dev/null
+++ b/LayoutTests/fast/workers/resources/worker-event-listener.js
@@ -0,0 +1,21 @@
+function gc()
+{
+ for (var i = 0; i < 10000; i++) { // > force garbage collection (FF requires about 9K allocations before a collect)
+ var s = new String("abc");
+ }
+}
+
+function onmessage(evt)
+{
+ try {
+ removeEventListener("message", onmessage, true);
+ addEventListener("message", function(e) { e.foo = "bar" }, true);
+ dispatchEvent(evt);
+ postMessage((evt.foo == "bar") ? "SUCCESS" : "FAIL");
+ } catch (ex) {
+ postMessage(ex);
+ }
+}
+
+addEventListener("message", onmessage, true);
+gc();
diff --git a/LayoutTests/fast/workers/worker-constructor-expected.txt b/LayoutTests/fast/workers/worker-constructor-expected.txt
new file mode 100644
index 0000000..97678d1
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-constructor-expected.txt
@@ -0,0 +1,8 @@
+Test Worker constructor functionality. Should print a series of PASS messages, followed with DONE.
+
+PASS: toString exception propagated correctly.
+PASS: trying to create workers recursively resulted in an exception (RangeError: Maximum call stack size exceeded.)
+PASS: invoking Worker constructor without arguments resulted in an exception (SyntaxError: Not enough arguments)
+PASS: onerror invoked for a script that could not be loaded.
+DONE
+
diff --git a/LayoutTests/fast/workers/worker-constructor.html b/LayoutTests/fast/workers/worker-constructor.html
new file mode 100644
index 0000000..8f8e723
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-constructor.html
@@ -0,0 +1,54 @@
+<body>
+<p>Test Worker constructor functionality. Should print a series of PASS messages, followed with DONE.</p>
+<div id=result></div>
+<script>
+function log(message)
+{
+ document.getElementById("result").innerHTML += message + "<br>";
+}
+
+if (window.layoutTestController) {
+ layoutTestController.dumpAsText();
+ layoutTestController.waitUntilDone();
+}
+
+try {
+ new Worker({toString:function(){throw "exception"}})
+ log("FAIL: toString exception not propagated.");
+} catch (ex) {
+ if (ex == "exception")
+ log("PASS: toString exception propagated correctly.");
+ else
+ log("FAIL: unexpected exception (" + ex + ") received instead of one propagated from toString.");
+}
+
+try {
+ var foo = {toString:function(){new Worker(foo)}}
+ new Worker(foo);
+ log("FAIL: no exception when trying to create workers recursively");
+} catch (ex) {
+ log("PASS: trying to create workers recursively resulted in an exception (" + ex + ")");
+}
+
+try {
+ new Worker();
+ log("FAIL: invoking Worker constructor without arguments did not result in an exception");
+} catch (ex) {
+ log("PASS: invoking Worker constructor without arguments resulted in an exception (" + ex + ")");
+}
+
+try {
+ var worker = new Worker("does-not-exist.js");
+ worker.onerror = function() {
+ log("PASS: onerror invoked for a script that could not be loaded.");
+ log("DONE");
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+ }
+} catch (ex) {
+ log("FAIL: unexpected exception " + ex);
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+}
+</script>
+</body>
diff --git a/LayoutTests/fast/workers/worker-event-listener-expected.txt b/LayoutTests/fast/workers/worker-event-listener-expected.txt
new file mode 100644
index 0000000..c83fdd5
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-event-listener-expected.txt
@@ -0,0 +1,4 @@
+Test EventTarget methods on workers. Should print "SUCCESS".
+
+SUCCESS
+
diff --git a/LayoutTests/fast/workers/worker-event-listener.html b/LayoutTests/fast/workers/worker-event-listener.html
new file mode 100644
index 0000000..899aba3
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-event-listener.html
@@ -0,0 +1,36 @@
+<body>
+<p>Test EventTarget methods on workers. Should print "SUCCESS".</p>
+<div id=result></div>
+<script>
+function log(message)
+{
+ document.getElementById("result").innerHTML += message + "<br>";
+}
+
+function gc()
+{
+ if (window.GCController)
+ return GCController.collect();
+
+ for (var i = 0; i < 10000; i++) { // > force garbage collection (FF requires about 9K allocations before a collect)
+ var s = new String("abc");
+ }
+}
+
+if (window.layoutTestController) {
+ layoutTestController.dumpAsText();
+ layoutTestController.waitUntilDone();
+}
+
+var worker = new Worker('resources/worker-event-listener.js');
+worker.postMessage("");
+worker.onmessage = function(evt) {
+ log(evt.data);
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+
+}
+gc();
+</script>
+</body>
+</html>
diff --git a/LayoutTests/fast/workers/worker-gc-expected.txt b/LayoutTests/fast/workers/worker-gc-expected.txt
new file mode 100644
index 0000000..631b3d1
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-gc-expected.txt
@@ -0,0 +1,4 @@
+Test worker garbage collection. Should print "SUCCESS".
+
+SUCCESS
+
diff --git a/LayoutTests/fast/workers/worker-gc.html b/LayoutTests/fast/workers/worker-gc.html
new file mode 100644
index 0000000..77c655b
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-gc.html
@@ -0,0 +1,43 @@
+<body>
+<p>Test worker garbage collection. Should print "SUCCESS".</p>
+<div id=result></div>
+<script>
+function log(message)
+{
+ document.getElementById("result").innerHTML += message + "<br>";
+}
+
+function gc()
+{
+ if (window.GCController)
+ return GCController.collect();
+
+ for (var i = 0; i < 10000; i++) { // > force garbage collection (FF requires about 9K allocations before a collect)
+ var s = new String("abc");
+ }
+}
+
+if (window.layoutTestController) {
+ layoutTestController.dumpAsText();
+ layoutTestController.waitUntilDone();
+}
+
+var interval = setInterval(gc, 0);
+
+var worker = new Worker('resources/worker-common.js');
+worker.postMessage("ping");
+worker.onmessage = function(evt) {
+ this.postMessage("ping");
+ this.onmessage = function() {
+ log("SUCCESS");
+ clearInterval(interval);
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+ }
+
+}
+worker = 0;
+gc();
+</script>
+</body>
+</html>
diff --git a/LayoutTests/fast/workers/worker-location-expected.txt b/LayoutTests/fast/workers/worker-location-expected.txt
new file mode 100644
index 0000000..21307fd
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-location-expected.txt
@@ -0,0 +1,14 @@
+Test WorkerLocation properties.
+
+typeof location: object
+location: file:<...>/fast/workers/resources/worker-common.js
+location.href: file:<...>/fast/workers/resources/worker-common.js
+location.protocol: file:
+location.host:
+location.hostname:
+location.port:
+location.pathname: <...>/fast/workers/resources/worker-common.js
+location.search:
+location.hash:
+DONE
+
diff --git a/LayoutTests/fast/workers/worker-location.html b/LayoutTests/fast/workers/worker-location.html
new file mode 100644
index 0000000..bcc6316
--- /dev/null
+++ b/LayoutTests/fast/workers/worker-location.html
@@ -0,0 +1,49 @@
+<body>
+<p>Test WorkerLocation properties.</p>
+<div id=result></div>
+<script>
+function log(message)
+{
+ document.getElementById("result").innerHTML += message + "<br>";
+}
+
+function gc()
+{
+ if (window.GCController)
+ return GCController.collect();
+
+ for (var i = 0; i < 10000; i++) { // > force garbage collection (FF requires about 9K allocations before a collect)
+ var s = new String("abc");
+ }
+}
+
+if (window.layoutTestController) {
+ layoutTestController.dumpAsText();
+ layoutTestController.waitUntilDone();
+}
+
+var worker = new Worker('resources/worker-common.js');
+worker.postMessage("eval typeof location");
+worker.postMessage("eval location");
+worker.postMessage("eval location.href");
+worker.postMessage("eval location.protocol");
+worker.postMessage("eval location.host");
+worker.postMessage("eval location.hostname");
+worker.postMessage("eval location.port");
+worker.postMessage("eval location.pathname");
+worker.postMessage("eval location.search");
+worker.postMessage("eval location.hash");
+worker.postMessage("eval foo//bar");
+
+worker.onmessage = function(evt) {
+ if (!/foo\/\/bar/.test(evt.data))
+ log(evt.data.replace(new RegExp("/.*LayoutTests"), "<...>"));
+ else {
+ log("DONE");
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+ }
+}
+</script>
+</body>
+</html>
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index fdcce3f..1b8337b 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,20 @@
+2008-11-18 Alexey Proskuryakov <ap@webkit.org>
+
+ Reviewed by Darin Adler.
+
+ https://bugs.webkit.org/show_bug.cgi?id=22337
+ Enable workers by default
+
+ Tests: fast/workers/worker-constructor.html
+ fast/workers/worker-event-listener.html
+ fast/workers/worker-gc.html
+ fast/workers/worker-location.html
+
+ * Configurations/WebCore.xcconfig:
+ * WebCore.vcproj/WebCore.vcproj:
+ * WebCore.vcproj/build-generated-files.sh:
+ Define ENABLE_WORKERS.
+
2008-11-18 Darin Adler <darin@apple.com>
Reviewed by Alexey Proskuryakov.
diff --git a/WebCore/Configurations/WebCore.xcconfig b/WebCore/Configurations/WebCore.xcconfig
index 7907fba..3d19f63 100644
--- a/WebCore/Configurations/WebCore.xcconfig
+++ b/WebCore/Configurations/WebCore.xcconfig
@@ -15,7 +15,7 @@
OTHER_LDFLAGS = -l$(SQLITE3_LIBRARY) -lobjc -sub_library libobjc -umbrella WebKit;
// This needs to be kept sorted, and in sync with FEATURE_DEFINES in JavaScriptCore.xcconfig, WebKit.xcconfig and the default settings of build-webkit.
-FEATURE_DEFINES = ENABLE_DATABASE ENABLE_DOM_STORAGE ENABLE_ICONDATABASE ENABLE_OFFLINE_WEB_APPLICATIONS ENABLE_SVG ENABLE_SVG_ANIMATION ENABLE_SVG_AS_IMAGE ENABLE_SVG_FONTS ENABLE_SVG_FOREIGN_OBJECT ENABLE_SVG_USE ENABLE_VIDEO ENABLE_XPATH ENABLE_XSLT;
+FEATURE_DEFINES = ENABLE_DATABASE ENABLE_DOM_STORAGE ENABLE_ICONDATABASE ENABLE_OFFLINE_WEB_APPLICATIONS ENABLE_SVG ENABLE_SVG_ANIMATION ENABLE_SVG_AS_IMAGE ENABLE_SVG_FONTS ENABLE_SVG_FOREIGN_OBJECT ENABLE_SVG_USE ENABLE_VIDEO ENABLE_WORKERS ENABLE_XPATH ENABLE_XSLT;
SQLITE3_LIBRARY = $(SQLITE3_LIBRARY_$(MAC_OS_X_VERSION_MAJOR));
SQLITE3_LIBRARY_ = WebCoreSQLite3;
diff --git a/WebCore/WebCore.vcproj/WebCore.vcproj b/WebCore/WebCore.vcproj/WebCore.vcproj
index d73af39..4afe616 100644
--- a/WebCore/WebCore.vcproj/WebCore.vcproj
+++ b/WebCore/WebCore.vcproj/WebCore.vcproj
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="windows-1251"?>
<VisualStudioProject
ProjectType="Visual C++"
- Version="8.00"
+ Version="8,00"
Name="WebCore"
ProjectGUID="{1C16337B-ACF3-4D03-AA90-851C5B5EADA6}"
RootNamespace="WebCore"
@@ -41,7 +41,7 @@
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories=""$(ProjectDir)..\";"$(ProjectDir)..";"$(ProjectDir)..\bridge";"$(ProjectDir)..\bridge\c";"$(ProjectDir)..\css";"$(ProjectDir)..\editing";"$(ProjectDir)..\rendering";"$(ProjectDir)..\rendering\style";"$(ProjectDir)..\bindings\js";"$(ProjectDir)..\dom";"$(ProjectDir)..\history";"$(ProjectDir)..\html";"$(ProjectDir)..\inspector";"$(ProjectDir)..\loader";"$(ProjectDir)..\loader\appcache";"$(ProjectDir)..\loader\archive";"$(ProjectDir)..\loader\archive\cf";"$(ProjectDir)..\loader\icon";"$(ProjectDir)..\page";"$(ProjectDir)..\page\animation";"$(ProjectDir)..\page\win";"$(ProjectDir)..\platform";"$(ProjectDir)..\platform\sql";"$(ProjectDir)..\platform\win";"$(ProjectDir)..\platform\network";"$(ProjectDir)..\platform\network\win";"$(ProjectDir)..\platform\cf";"$(ProjectDir)..\platform\network\cf";"$(ProjectDir)..\platform\graphics";"$(ProjectDir)..\platform\text";"$(ProjectDir)..\platform\graphics\cg";"$(ProjectDir)..\platform\graphics\win";"$(ProjectDir)..\xml";"$(WebKitOutputDir)\obj\WebCore\DerivedSources";"$(ProjectDir)..\plugins";"$(ProjectDir)..\plugins\win";"$(ProjectDir)..\platform\cairo\pixman\src";"$(ProjectDir)..\platform\cairo\cairo\src";"$(ProjectDir)..\svg\graphics";"$(ProjectDir)..\svg\graphics\cg";"$(ProjectDir)..\svg\graphics\filters";"$(ProjectDir)..\svg";"$(ProjectDir)..\storage";"$(WebKitOutputDir)\include";"$(WebKitOutputDir)\include\JavaScriptCore";"$(ProjectDir)..\ForwardingHeaders";"$(WebKitLibrariesDir)\include";"$(WebKitLibrariesDir)\include\icu";"$(WebKitLibrariesDir)\include\iconv";"$(WebKitLibrariesDir)\include\pthreads";"$(WebKitLibrariesDir)\include\sqlite";"$(WebKitLibrariesDir)\include\JavaScriptCore";"$(WebKitLibrariesDir)\Include\CoreFoundation\OSXCompatibilityHeaders";"$(WebKitLibrariesDir)\Include\CoreFoundation\OSXCompatibilityHeaders\GNUCompatibility";"$(WebKitOutputDir)\include\QtMovieWin";"$(ProjectDir)..\svg\animation""
- PreprocessorDefinitions="__WIN32__;ENABLE_DOM_STORAGE;ENABLE_OFFLINE_WEB_APPLICATIONS;ENABLE_SVG;ENABLE_SVG_ANIMATION;ENABLE_SVG_AS_IMAGE;ENABLE_SVG_USE;ENABLE_SVG_FOREIGN_OBJECT;ENABLE_SVG_FONTS;WEBCORE_CONTEXT_MENUS;ENABLE_VIDEO;ENABLE_XSLT;ENABLE_XPATH"
+ PreprocessorDefinitions="__WIN32__;ENABLE_DOM_STORAGE;ENABLE_OFFLINE_WEB_APPLICATIONS;ENABLE_SVG;ENABLE_SVG_ANIMATION;ENABLE_SVG_AS_IMAGE;ENABLE_SVG_USE;ENABLE_SVG_FOREIGN_OBJECT;ENABLE_SVG_FONTS;WEBCORE_CONTEXT_MENUS;ENABLE_WORKERS;ENABLE_VIDEO;ENABLE_XSLT;ENABLE_XPATH"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="WebCorePrefix.h"
ForcedIncludeFiles="WebCorePrefix.h"
@@ -102,7 +102,7 @@
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories=""$(ProjectDir)..\";"$(ProjectDir)..";"$(ProjectDir)..\bridge";"$(ProjectDir)..\bridge\c";"$(ProjectDir)..\css";"$(ProjectDir)..\editing";"$(ProjectDir)..\rendering";"$(ProjectDir)..\rendering\style";"$(ProjectDir)..\bindings\js";"$(ProjectDir)..\dom";"$(ProjectDir)..\history";"$(ProjectDir)..\html";"$(ProjectDir)..\inspector";"$(ProjectDir)..\loader";"$(ProjectDir)..\loader\appcache";"$(ProjectDir)..\loader\archive";"$(ProjectDir)..\loader\archive\cf";"$(ProjectDir)..\loader\icon";"$(ProjectDir)..\page";"$(ProjectDir)..\page\animation";"$(ProjectDir)..\page\win";"$(ProjectDir)..\platform";"$(ProjectDir)..\platform\sql";"$(ProjectDir)..\platform\win";"$(ProjectDir)..\platform\network";"$(ProjectDir)..\platform\network\win";"$(ProjectDir)..\platform\cf";"$(ProjectDir)..\platform\network\cf";"$(ProjectDir)..\platform\graphics";"$(ProjectDir)..\platform\text";"$(ProjectDir)..\platform\graphics\cg";"$(ProjectDir)..\platform\graphics\win";"$(ProjectDir)..\xml";"$(WebKitOutputDir)\obj\WebCore\DerivedSources";"$(ProjectDir)..\plugins";"$(ProjectDir)..\plugins\win";"$(ProjectDir)..\svg\graphics";"$(ProjectDir)..\svg\graphics\cg";"$(ProjectDir)..\svg\graphics\filters";"$(ProjectDir)..\svg";"$(ProjectDir)..\storage";"$(WebKitOutputDir)\include";"$(WebKitOutputDir)\include\JavaScriptCore";"$(ProjectDir)..\ForwardingHeaders";"$(WebKitLibrariesDir)\include";"$(WebKitLibrariesDir)\include\icu";"$(WebKitLibrariesDir)\include\iconv";"$(WebKitLibrariesDir)\include\pthreads";"$(WebKitLibrariesDir)\include\sqlite";"$(WebKitLibrariesDir)\include\JavaScriptCore";"$(WebKitLibrariesDir)\Include\CoreFoundation\OSXCompatibilityHeaders";"$(WebKitLibrariesDir)\Include\CoreFoundation\OSXCompatibilityHeaders\GNUCompatibility";"$(WebKitOutputDir)\include\QtMovieWin";"$(ProjectDir)..\svg\animation""
- PreprocessorDefinitions="__WIN32__;ENABLE_DOM_STORAGE;ENABLE_OFFLINE_WEB_APPLICATIONS;ENABLE_SVG;ENABLE_SVG_ANIMATION;ENABLE_SVG_AS_IMAGE;ENABLE_SVG_USE;ENABLE_SVG_FOREIGN_OBJECT;ENABLE_SVG_FONTS;WEBCORE_CONTEXT_MENUS;ENABLE_VIDEO;ENABLE_XSLT;ENABLE_XPATH"
+ PreprocessorDefinitions="__WIN32__;ENABLE_DOM_STORAGE;ENABLE_OFFLINE_WEB_APPLICATIONS;ENABLE_SVG;ENABLE_SVG_ANIMATION;ENABLE_SVG_AS_IMAGE;ENABLE_SVG_USE;ENABLE_SVG_FOREIGN_OBJECT;ENABLE_SVG_FONTS;WEBCORE_CONTEXT_MENUS;ENABLE_WORKERS;ENABLE_VIDEO;ENABLE_XSLT;ENABLE_XPATH"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="WebCorePrefix.h"
ForcedIncludeFiles="WebCorePrefix.h"
@@ -162,7 +162,7 @@
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories=""$(ProjectDir)..\";"$(ProjectDir)..";"$(ProjectDir)..\bridge";"$(ProjectDir)..\bridge\c";"$(ProjectDir)..\css";"$(ProjectDir)..\editing";"$(ProjectDir)..\rendering";"$(ProjectDir)..\rendering\style";"$(ProjectDir)..\bindings\js";"$(ProjectDir)..\dom";"$(ProjectDir)..\history";"$(ProjectDir)..\html";"$(ProjectDir)..\inspector";"$(ProjectDir)..\loader";"$(ProjectDir)..\loader\appcache";"$(ProjectDir)..\loader\archive";"$(ProjectDir)..\loader\archive\cf";"$(ProjectDir)..\loader\icon";"$(ProjectDir)..\page";"$(ProjectDir)..\page\animation";"$(ProjectDir)..\page\win";"$(ProjectDir)..\platform";"$(ProjectDir)..\platform\sql";"$(ProjectDir)..\platform\win";"$(ProjectDir)..\platform\network";"$(ProjectDir)..\platform\network\win";"$(ProjectDir)..\platform\cf";"$(ProjectDir)..\platform\network\cf";"$(ProjectDir)..\platform\graphics";"$(ProjectDir)..\platform\text";"$(ProjectDir)..\platform\graphics\cg";"$(ProjectDir)..\platform\graphics\win";"$(ProjectDir)..\xml";"$(WebKitOutputDir)\obj\WebCore\DerivedSources";"$(ProjectDir)..\plugins";"$(ProjectDir)..\plugins\win";"$(ProjectDir)..\svg\graphics";"$(ProjectDir)..\svg\graphics\cg";"$(ProjectDir)..\svg\graphics\filters";"$(ProjectDir)..\svg";"$(ProjectDir)..\storage";"$(WebKitOutputDir)\include";"$(WebKitOutputDir)\include\JavaScriptCore";"$(ProjectDir)..\ForwardingHeaders";"$(WebKitLibrariesDir)\include";"$(WebKitLibrariesDir)\include\icu";"$(WebKitLibrariesDir)\include\iconv";"$(WebKitLibrariesDir)\include\pthreads";"$(WebKitLibrariesDir)\include\sqlite";"$(WebKitLibrariesDir)\include\JavaScriptCore";"$(WebKitLibrariesDir)\Include\CoreFoundation\OSXCompatibilityHeaders";"$(WebKitLibrariesDir)\Include\CoreFoundation\OSXCompatibilityHeaders\GNUCompatibility";"$(WebKitOutputDir)\include\QtMovieWin";"$(ProjectDir)..\svg\animation""
- PreprocessorDefinitions="__WIN32__;ENABLE_DOM_STORAGE;ENABLE_OFFLINE_WEB_APPLICATIONS;ENABLE_SVG;ENABLE_SVG_ANIMATION;ENABLE_SVG_AS_IMAGE;ENABLE_SVG_USE;ENABLE_SVG_FOREIGN_OBJECT;ENABLE_SVG_FONTS;WEBCORE_CONTEXT_MENUS;ENABLE_VIDEO;ENABLE_XSLT;ENABLE_XPATH"
+ PreprocessorDefinitions="__WIN32__;ENABLE_DOM_STORAGE;ENABLE_OFFLINE_WEB_APPLICATIONS;ENABLE_SVG;ENABLE_SVG_ANIMATION;ENABLE_SVG_AS_IMAGE;ENABLE_SVG_USE;ENABLE_SVG_FOREIGN_OBJECT;ENABLE_SVG_FONTS;WEBCORE_CONTEXT_MENUS;ENABLE_WORKERS;ENABLE_VIDEO;ENABLE_XSLT;ENABLE_XPATH"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="WebCorePrefix.h"
ForcedIncludeFiles="WebCorePrefix.h"
@@ -347,7 +347,7 @@
Name="VCCLCompilerTool"
WholeProgramOptimization="false"
AdditionalIncludeDirectories=""$(ProjectDir)..\";"$(ProjectDir)..";"$(ProjectDir)..\bridge";"$(ProjectDir)..\bridge\c";"$(ProjectDir)..\css";"$(ProjectDir)..\editing";"$(ProjectDir)..\rendering";"$(ProjectDir)..\rendering\style";"$(ProjectDir)..\bindings\js";"$(ProjectDir)..\dom";"$(ProjectDir)..\history";"$(ProjectDir)..\html";"$(ProjectDir)..\inspector";"$(ProjectDir)..\loader";"$(ProjectDir)..\loader\appcache";"$(ProjectDir)..\loader\archive";"$(ProjectDir)..\loader\archive\cf";"$(ProjectDir)..\loader\icon";"$(ProjectDir)..\page";"$(ProjectDir)..\page\animation";"$(ProjectDir)..\page\win";"$(ProjectDir)..\platform";"$(ProjectDir)..\platform\sql";"$(ProjectDir)..\platform\win";"$(ProjectDir)..\platform\network";"$(ProjectDir)..\platform\network\win";"$(ProjectDir)..\platform\cf";"$(ProjectDir)..\platform\network\cf";"$(ProjectDir)..\platform\graphics";"$(ProjectDir)..\platform\text";"$(ProjectDir)..\platform\graphics\cg";"$(ProjectDir)..\platform\graphics\win";"$(ProjectDir)..\xml";"$(WebKitOutputDir)\obj\WebCore\DerivedSources";"$(ProjectDir)..\plugins";"$(ProjectDir)..\plugins\win";"$(ProjectDir)..\svg\graphics";"$(ProjectDir)..\svg\graphics\cg";"$(ProjectDir)..\svg\graphics\filters";"$(ProjectDir)..\svg";"$(ProjectDir)..\storage";"$(WebKitOutputDir)\include";"$(WebKitOutputDir)\include\JavaScriptCore";"$(ProjectDir)..\ForwardingHeaders";"$(WebKitLibrariesDir)\include";"$(WebKitLibrariesDir)\include\icu";"$(WebKitLibrariesDir)\include\iconv";"$(WebKitLibrariesDir)\include\pthreads";"$(WebKitLibrariesDir)\include\sqlite";"$(WebKitLibrariesDir)\include\JavaScriptCore";"$(WebKitLibrariesDir)\Include\CoreFoundation\OSXCompatibilityHeaders";"$(WebKitLibrariesDir)\Include\CoreFoundation\OSXCompatibilityHeaders\GNUCompatibility";"$(WebKitOutputDir)\include\QtMovieWin";"$(ProjectDir)..\svg\animation""
- PreprocessorDefinitions="__WIN32__;ENABLE_DOM_STORAGE;ENABLE_OFFLINE_WEB_APPLICATIONS;ENABLE_SVG;ENABLE_SVG_ANIMATION;ENABLE_SVG_AS_IMAGE;ENABLE_SVG_USE;ENABLE_SVG_FOREIGN_OBJECT;ENABLE_SVG_FONTS;WEBCORE_CONTEXT_MENUS;ENABLE_VIDEO;ENABLE_XSLT;ENABLE_XPATH"
+ PreprocessorDefinitions="__WIN32__;ENABLE_DOM_STORAGE;ENABLE_OFFLINE_WEB_APPLICATIONS;ENABLE_SVG;ENABLE_SVG_ANIMATION;ENABLE_SVG_AS_IMAGE;ENABLE_SVG_USE;ENABLE_SVG_FOREIGN_OBJECT;ENABLE_SVG_FONTS;WEBCORE_CONTEXT_MENUS;ENABLE_WORKERS;ENABLE_VIDEO;ENABLE_XSLT;ENABLE_XPATH"
PrecompiledHeaderThrough="WebCorePrefix.h"
ForcedIncludeFiles="WebCorePrefix.h"
/>
@@ -1736,6 +1736,26 @@
>
</File>
<File
+ RelativePath="..\..\WebKitBuild\obj\WebCore\DerivedSources\JSWorker.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\..\WebKitBuild\obj\WebCore\DerivedSources\JSWorker.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\WebKitBuild\obj\WebCore\DerivedSources\JSWorkerContext.lut.h"
+ >
+ </File>
+ <File
+ RelativePath="..\..\WebKitBuild\obj\WebCore\DerivedSources\JSWorkerLocation.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\..\WebKitBuild\obj\WebCore\DerivedSources\JSWorkerLocation.h"
+ >
+ </File>
+ <File
RelativePath="$(WebKitOutputDir)\obj\$(ProjectName)\DerivedSources\JSXMLHttpRequest.h"
>
</File>
@@ -11378,6 +11398,54 @@
>
</File>
<File
+ RelativePath="..\dom\Worker.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\Worker.h"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerContext.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerContext.h"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerLocation.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerLocation.h"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerMessagingProxy.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerMessagingProxy.h"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerTask.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerTask.h"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerThread.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\dom\WorkerThread.h"
+ >
+ </File>
+ <File
RelativePath="..\dom\XMLTokenizer.cpp"
>
<FileConfiguration
@@ -13725,6 +13793,26 @@
>
</File>
<File
+ RelativePath="..\bindings\js\JSWorkerConstructor.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\bindings\js\JSWorkerConstructor.h"
+ >
+ </File>
+ <File
+ RelativePath="..\bindings\js\JSWorkerContext.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\bindings\js\JSWorkerContext.h"
+ >
+ </File>
+ <File
+ RelativePath="..\bindings\js\JSWorkerCustom.cpp"
+ >
+ </File>
+ <File
RelativePath="..\bindings\js\JSXMLHttpRequestConstructor.cpp"
>
</File>
@@ -13784,6 +13872,14 @@
RelativePath="..\bindings\js\StringSourceProvider.h"
>
</File>
+ <File
+ RelativePath="..\bindings\js\WorkerScriptController.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\bindings\js\WorkerScriptController.h"
+ >
+ </File>
</Filter>
</Filter>
<Filter
diff --git a/WebCore/WebCore.vcproj/build-generated-files.sh b/WebCore/WebCore.vcproj/build-generated-files.sh
index 7a0600a..cd79b39 100644
--- a/WebCore/WebCore.vcproj/build-generated-files.sh
+++ b/WebCore/WebCore.vcproj/build-generated-files.sh
@@ -65,5 +65,5 @@
cd "${BUILT_PRODUCTS_DIR}/DerivedSources"
export WebCore="${XSRCROOT}"
-export FEATURE_DEFINES="ENABLE_DATABASE ENABLE_DOM_STORAGE ENABLE_ICONDATABASE ENABLE_OFFLINE_WEB_APPLICATIONS ENABLE_XPATH ENABLE_SVG ENABLE_SVG_ANIMATION ENABLE_SVG_FONTS ENABLE_SVG_FOREIGN_OBJECT ENABLE_SVG_AS_IMAGE ENABLE_SVG_USE ENABLE_VIDEO"
+export FEATURE_DEFINES="ENABLE_DATABASE ENABLE_DOM_STORAGE ENABLE_ICONDATABASE ENABLE_OFFLINE_WEB_APPLICATIONS ENABLE_XPATH ENABLE_SVG ENABLE_SVG_ANIMATION ENABLE_SVG_FONTS ENABLE_SVG_FOREIGN_OBJECT ENABLE_SVG_AS_IMAGE ENABLE_SVG_USE ENABLE_WORKERS ENABLE_VIDEO"
make -f "$WebCore/DerivedSources.make" -j ${NUMCPUS} || exit 1
diff --git a/WebKit/mac/ChangeLog b/WebKit/mac/ChangeLog
index 1bb55ee..0266139 100644
--- a/WebKit/mac/ChangeLog
+++ b/WebKit/mac/ChangeLog
@@ -1,3 +1,13 @@
+2008-11-18 Alexey Proskuryakov <ap@webkit.org>
+
+ Reviewed by Darin Adler.
+
+ https://bugs.webkit.org/show_bug.cgi?id=22337
+ Enable workers by default
+
+ * Configurations/WebKit.xcconfig: Define ENABLE_WORKERS (change from ENABLE_WORKER_THREADS,
+ which was accidentally committed before).
+
2008-11-17 Geoffrey Garen <ggaren@apple.com>
Not reviewed.
diff --git a/WebKit/mac/Configurations/WebKit.xcconfig b/WebKit/mac/Configurations/WebKit.xcconfig
index 8deb186..0937fdb 100644
--- a/WebKit/mac/Configurations/WebKit.xcconfig
+++ b/WebKit/mac/Configurations/WebKit.xcconfig
@@ -18,4 +18,4 @@
OTHER_LDFLAGS = -sub_umbrella WebCore $(OTHER_LDFLAGS);
// This needs to be kept sorted, and in sync with FEATURE_DEFINES in JavaScriptCore.xcconfig, WebCore.xcconfig and the default settings of build-webkit.
-FEATURE_DEFINES = ENABLE_DATABASE ENABLE_DOM_STORAGE ENABLE_ICONDATABASE ENABLE_OFFLINE_WEB_APPLICATIONS ENABLE_SVG ENABLE_SVG_ANIMATION ENABLE_SVG_AS_IMAGE ENABLE_SVG_FONTS ENABLE_SVG_FOREIGN_OBJECT ENABLE_SVG_USE ENABLE_VIDEO ENABLE_WORKER_THREADS ENABLE_XPATH ENABLE_XSLT;
+FEATURE_DEFINES = ENABLE_DATABASE ENABLE_DOM_STORAGE ENABLE_ICONDATABASE ENABLE_OFFLINE_WEB_APPLICATIONS ENABLE_SVG ENABLE_SVG_ANIMATION ENABLE_SVG_AS_IMAGE ENABLE_SVG_FONTS ENABLE_SVG_FOREIGN_OBJECT ENABLE_SVG_USE ENABLE_VIDEO ENABLE_WORKERS ENABLE_XPATH ENABLE_XSLT;
diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index c720ea7..4c4835b 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,5 +1,14 @@
2008-11-18 Alexey Proskuryakov <ap@webkit.org>
+ Reviewed by Darin Adler.
+
+ https://bugs.webkit.org/show_bug.cgi?id=22337
+ Enable workers by default
+
+ * Scripts/build-webkit: Changed the default to enabled.
+
+2008-11-18 Alexey Proskuryakov <ap@webkit.org>
+
Rubber-stamped by Darin Adler.
https://bugs.webkit.org/show_bug.cgi?id=22306
diff --git a/WebKitTools/Scripts/build-webkit b/WebKitTools/Scripts/build-webkit
index 74d0733..5f870e0 100755
--- a/WebKitTools/Scripts/build-webkit
+++ b/WebKitTools/Scripts/build-webkit
@@ -57,7 +57,7 @@
my $wmlSupport = 0;
my $coverageSupport = 0;
my $videoSupport = (isOSX() || isCygwin()); # Enable by default on OSX and Windows
-my $workersSupport = 0;
+my $workersSupport = (isOSX() || isCygwin()); # Enable by default on OSX and Windows
my $showHelp = 0;
my $clean = 0;
my $buildUniversal = 0;