Title: [141818] trunk/Source
Revision
141818
Author
[email protected]
Date
2013-02-04 14:49:08 -0800 (Mon, 04 Feb 2013)

Log Message

[Chromium] Move WorkerContextProxy to WebCore
https://bugs.webkit.org/show_bug.cgi?id=108847

Reviewed by Adam Barth.

Part of a larger refactoring series; see tracking bug 106829.

Source/WebCore:

* WebCore.gyp/WebCore.gyp:
* WebCore.gypi:
* workers/chromium: Added.
* workers/chromium/WorkerContextProxyChromium.cpp: Added.
(WebCore):
(WebCore::setWorkerContextProxyCreateFunction):
(WebCore::WorkerContextProxy::create):
* workers/chromium/WorkerContextProxyChromium.h: Added.
(WebCore):

Source/WebKit/chromium:

* WebKit.gyp:
* src/WebKit.cpp:
(WebKit::initializeWithoutV8):
* src/WorkerContextProxy.cpp: Removed.

Modified Paths

Added Paths

Removed Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (141817 => 141818)


--- trunk/Source/WebCore/ChangeLog	2013-02-04 22:39:16 UTC (rev 141817)
+++ trunk/Source/WebCore/ChangeLog	2013-02-04 22:49:08 UTC (rev 141818)
@@ -1,3 +1,22 @@
+2013-02-04  Mark Pilgrim  <[email protected]>
+
+        [Chromium] Move WorkerContextProxy to WebCore
+        https://bugs.webkit.org/show_bug.cgi?id=108847
+
+        Reviewed by Adam Barth.
+
+        Part of a larger refactoring series; see tracking bug 106829.
+
+        * WebCore.gyp/WebCore.gyp:
+        * WebCore.gypi:
+        * workers/chromium: Added.
+        * workers/chromium/WorkerContextProxyChromium.cpp: Added.
+        (WebCore):
+        (WebCore::setWorkerContextProxyCreateFunction):
+        (WebCore::WorkerContextProxy::create):
+        * workers/chromium/WorkerContextProxyChromium.h: Added.
+        (WebCore):
+
 2013-02-04  Dima Gorbik  <[email protected]>
 
         WebVTT <i>, <b> and <u> elements should have default styles

Modified: trunk/Source/WebCore/WebCore.gyp/WebCore.gyp (141817 => 141818)


--- trunk/Source/WebCore/WebCore.gyp/WebCore.gyp	2013-02-04 22:39:16 UTC (rev 141817)
+++ trunk/Source/WebCore/WebCore.gyp/WebCore.gyp	2013-02-04 22:49:08 UTC (rev 141818)
@@ -153,6 +153,7 @@
       '../svg/properties',
       '../../ThirdParty/glu',
       '../workers',
+      '../workers/chromium',
       '../xml',
       '../xml/parser',
     ],

Modified: trunk/Source/WebCore/WebCore.gypi (141817 => 141818)


--- trunk/Source/WebCore/WebCore.gypi	2013-02-04 22:39:16 UTC (rev 141817)
+++ trunk/Source/WebCore/WebCore.gypi	2013-02-04 22:49:08 UTC (rev 141818)
@@ -2646,6 +2646,8 @@
             'workers/WorkerScriptLoader.h',
             'workers/WorkerScriptLoaderClient.h',
             'workers/WorkerThread.cpp',
+            'workers/chromium/WorkerContextProxyChromium.cpp',
+            'workers/chromium/WorkerContextProxyChromium.h',
             'xml/parser/CharacterReferenceParserInlines.h',
             'xml/parser/MarkupTokenBase.h',
             'xml/parser/MarkupTokenizerBase.h',

Copied: trunk/Source/WebCore/workers/chromium/WorkerContextProxyChromium.cpp (from rev 141817, trunk/Source/WebKit/chromium/src/WorkerContextProxy.cpp) (0 => 141818)


--- trunk/Source/WebCore/workers/chromium/WorkerContextProxyChromium.cpp	                        (rev 0)
+++ trunk/Source/WebCore/workers/chromium/WorkerContextProxyChromium.cpp	2013-02-04 22:49:08 UTC (rev 141818)
@@ -0,0 +1,53 @@
+/*
+ * Copyright (C) 2012 Google 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:
+ *
+ *     * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *     * 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.
+ *     * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "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 THE COPYRIGHT
+ * OWNER 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 "WorkerContextProxyChromium.h"
+
+#if ENABLE(WORKERS)
+
+namespace WebCore {
+
+static WorkerContextProxyCreate* s_workerContextProxyCreateFunction = 0;
+
+void setWorkerContextProxyCreateFunction(WorkerContextProxyCreate workerContextProxyCreateFunction)
+{
+    s_workerContextProxyCreateFunction = workerContextProxyCreateFunction;
+}
+
+WorkerContextProxy* WorkerContextProxy::create(Worker* worker)
+{
+    ASSERT(s_workerContextProxyCreateFunction);
+    return s_workerContextProxyCreateFunction(worker);
+}
+
+} // namespace WebCore
+
+#endif

Added: trunk/Source/WebCore/workers/chromium/WorkerContextProxyChromium.h (0 => 141818)


--- trunk/Source/WebCore/workers/chromium/WorkerContextProxyChromium.h	                        (rev 0)
+++ trunk/Source/WebCore/workers/chromium/WorkerContextProxyChromium.h	2013-02-04 22:49:08 UTC (rev 141818)
@@ -0,0 +1,45 @@
+/*
+ * Copyright (C) 2013 Google 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.
+ * 3.  Neither the name of Google, Inc. ("Google") nor the names of
+ *     its contributors may be used to endorse or promote products derived
+ *     from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "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 OR ITS 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 WorkerContextProxyChromium_h
+#define WorkerContextProxyChromium_h
+
+#include "WorkerContextProxy.h"
+
+#if ENABLE(WORKERS)
+
+namespace WebCore {
+
+typedef WorkerContextProxy* WorkerContextProxyCreate(Worker*);
+
+void setWorkerContextProxyCreateFunction(WorkerContextProxyCreate);
+
+} // namespace WebCore
+
+#endif
+
+#endif // WorkerContextProxyChromium_h

Modified: trunk/Source/WebKit/chromium/ChangeLog (141817 => 141818)


--- trunk/Source/WebKit/chromium/ChangeLog	2013-02-04 22:39:16 UTC (rev 141817)
+++ trunk/Source/WebKit/chromium/ChangeLog	2013-02-04 22:49:08 UTC (rev 141818)
@@ -1,3 +1,17 @@
+2013-02-04  Mark Pilgrim  <[email protected]>
+
+        [Chromium] Move WorkerContextProxy to WebCore
+        https://bugs.webkit.org/show_bug.cgi?id=108847
+
+        Reviewed by Adam Barth.
+
+        Part of a larger refactoring series; see tracking bug 106829.
+
+        * WebKit.gyp:
+        * src/WebKit.cpp:
+        (WebKit::initializeWithoutV8):
+        * src/WorkerContextProxy.cpp: Removed.
+
 2013-02-04  Abhishek Arya  <[email protected]>
 
         Add ASSERT_WITH_SECURITY_IMPLICATION to detect out of bounds access

Modified: trunk/Source/WebKit/chromium/WebKit.gyp (141817 => 141818)


--- trunk/Source/WebKit/chromium/WebKit.gyp	2013-02-04 22:39:16 UTC (rev 141817)
+++ trunk/Source/WebKit/chromium/WebKit.gyp	2013-02-04 22:49:08 UTC (rev 141818)
@@ -595,7 +595,6 @@
                 'src/WorkerAsyncFileSystemChromium.h',
                 'src/WorkerAsyncFileWriterChromium.cpp',
                 'src/WorkerAsyncFileWriterChromium.h',
-                'src/WorkerContextProxy.cpp',
                 'src/WorkerFileSystemCallbacksBridge.cpp',
                 'src/WorkerFileSystemCallbacksBridge.h',
                 'src/WorkerFileWriterCallbacksBridge.cpp',

Modified: trunk/Source/WebKit/chromium/src/WebKit.cpp (141817 => 141818)


--- trunk/Source/WebKit/chromium/src/WebKit.cpp	2013-02-04 22:39:16 UTC (rev 141817)
+++ trunk/Source/WebKit/chromium/src/WebKit.cpp	2013-02-04 22:49:08 UTC (rev 141818)
@@ -62,6 +62,11 @@
 #include "WebMediaPlayerClientImpl.h"
 #endif
 
+#if ENABLE(WORKERS)
+#include "WebWorkerClientImpl.h"
+#include "WorkerContextProxyChromium.h"
+#endif
+
 #if OS(DARWIN)
 #include "WebSystemInterface.h"
 #endif
@@ -159,6 +164,10 @@
 #if ENABLE(VIDEO)
     WebCore::MediaPlayerPrivate::setMediaEngineRegisterSelfFunction(WebKit::WebMediaPlayerClientImpl::registerSelf);
 #endif
+
+#if ENABLE(WORKERS)
+    WebCore::setWorkerContextProxyCreateFunction(WebWorkerClientImpl::createWorkerContextProxy);
+#endif
 }
 
 

Deleted: trunk/Source/WebKit/chromium/src/WorkerContextProxy.cpp (141817 => 141818)


--- trunk/Source/WebKit/chromium/src/WorkerContextProxy.cpp	2013-02-04 22:39:16 UTC (rev 141817)
+++ trunk/Source/WebKit/chromium/src/WorkerContextProxy.cpp	2013-02-04 22:49:08 UTC (rev 141818)
@@ -1,49 +0,0 @@
-/*
- * Copyright (C) 2012 Google 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:
- *
- *     * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *     * 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.
- *     * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "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 THE COPYRIGHT
- * OWNER 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 "WorkerContextProxy.h"
-
-#include "WebWorkerClientImpl.h"
-
-// We are part of the WebKit implementation.
-using namespace WebKit;
-
-namespace WebCore {
-
-#if ENABLE(WORKERS)
-WorkerContextProxy* WorkerContextProxy::create(Worker* worker)
-{
-    return WebWorkerClientImpl::createWorkerContextProxy(worker);
-}
-
-} // namespace WebCore
-
-#endif
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to