Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(304)

Unified Diff: Source/bindings/modules/v8/ModuleBindingsInitializer.cpp

Issue 551003002: bindings: Removes unnecessary Event-related code. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Pushed V8EventTargetCustom.cpp back with modification. Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/bindings/modules/generated.gyp ('k') | Source/build/scripts/make_event_factory.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/modules/v8/ModuleBindingsInitializer.cpp
diff --git a/Source/bindings/modules/v8/ModuleBindingsInitializer.cpp b/Source/bindings/modules/v8/ModuleBindingsInitializer.cpp
index 19edd04fa936d62ecadbbce4adc492752f2d01c5..ff087e35dc2c70ff719811c56b0b8a6636c00e92 100644
--- a/Source/bindings/modules/v8/ModuleBindingsInitializer.cpp
+++ b/Source/bindings/modules/v8/ModuleBindingsInitializer.cpp
@@ -6,53 +6,11 @@
#include "bindings/modules/v8/ModuleBindingsInitializer.h"
#include "bindings/core/v8/ModuleProxy.h"
-#include "bindings/core/v8/V8Event.h"
-#include "bindings/core/v8/V8EventTarget.h"
-#include "modules/EventModulesHeaders.h"
-#include "modules/EventModulesInterfaces.h"
-#include "modules/EventTargetModulesHeaders.h"
-#include "modules/EventTargetModulesInterfaces.h"
+#include "core/dom/ExecutionContext.h"
#include "modules/indexeddb/IDBPendingTransactionMonitor.h"
namespace blink {
-#define TRY_TO_WRAP_WITH_INTERFACE(interfaceName) \
- if (EventNames::interfaceName == desiredInterface) \
- return wrap(static_cast<interfaceName*>(event), creationContext, isolate);
-
-static v8::Handle<v8::Object> wrapForModuleEvent(Event* event, v8::Handle<v8::Object> creationContext, v8::Isolate *isolate)
-{
- ASSERT(event);
-
- String desiredInterface = event->interfaceName();
- EVENT_MODULES_INTERFACES_FOR_EACH(TRY_TO_WRAP_WITH_INTERFACE);
-
- // Wrapping for core event types should have been tried before this
- // function was called, so |event| should have been a module event type.
- // If this ASSERT is hit, the event type was missing from both
- // enumerations.
- ASSERT_NOT_REACHED();
- return v8::Handle<v8::Object>();
-}
-
-#undef TRY_TO_WRAP_WITH_INTERFACE
-
-#define TRY_TO_TOV8_WITH_INTERFACE(interfaceName) \
- if (EventTargetNames::interfaceName == desiredInterface) \
- return toV8(static_cast<interfaceName*>(impl), creationContext, isolate);
-
-static v8::Handle<v8::Value> toV8ForModuleEventTarget(EventTarget* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
-{
- ASSERT(impl);
- AtomicString desiredInterface = impl->interfaceName();
- EVENT_TARGET_MODULES_INTERFACES_FOR_EACH(TRY_TO_TOV8_WITH_INTERFACE)
-
- ASSERT_NOT_REACHED();
- return v8Undefined();
-}
-
-#undef TRY_TO_TOV8_WITH_INTERFACE
-
static void didLeaveScriptContextForModule(ExecutionContext& executionContext)
{
// Indexed DB requires that transactions are created with an internal |active| flag
@@ -62,8 +20,6 @@ static void didLeaveScriptContextForModule(ExecutionContext& executionContext)
void ModuleBindingsInitializer::init()
{
- ModuleProxy::moduleProxy().registerWrapForEvent(wrapForModuleEvent);
- ModuleProxy::moduleProxy().registerToV8ForEventTarget(toV8ForModuleEventTarget);
ModuleProxy::moduleProxy().registerDidLeaveScriptContextForRecursionScope(didLeaveScriptContextForModule);
}
« no previous file with comments | « Source/bindings/modules/generated.gyp ('k') | Source/build/scripts/make_event_factory.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698