| Index: Source/bindings/core/v8/custom/V8HTMLMediaElementCustom.cpp
|
| diff --git a/Source/bindings/core/v8/custom/V8HTMLMediaElementCustom.cpp b/Source/bindings/core/v8/custom/V8HTMLMediaElementCustom.cpp
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..a841eb210ea3b54cd4070a65daa7ce35c229f980
|
| --- /dev/null
|
| +++ b/Source/bindings/core/v8/custom/V8HTMLMediaElementCustom.cpp
|
| @@ -0,0 +1,26 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include "config.h"
|
| +#include "bindings/core/v8/V8HTMLMediaElement.h"
|
| +
|
| +#include "bindings/core/v8/V8HTMLAudioElement.h"
|
| +#include "bindings/core/v8/V8HTMLVideoElement.h"
|
| +
|
| +namespace blink {
|
| +
|
| +v8::Handle<v8::Object> wrap(HTMLMediaElement* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
|
| +{
|
| + ASSERT(impl);
|
| +
|
| + if (isHTMLAudioElement(impl))
|
| + return wrap(toHTMLAudioElement(impl), creationContext, isolate);
|
| + if (isHTMLVideoElement(impl))
|
| + return wrap(toHTMLVideoElement(impl), creationContext, isolate);
|
| +
|
| + ASSERT(!DOMDataStore::containsWrapper<V8HTMLMediaElement>(impl, isolate));
|
| + return V8HTMLMediaElement::createWrapper(impl, creationContext, isolate);
|
| +}
|
| +
|
| +} // namespace blink
|
|
|