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

Side by Side Diff: Source/bindings/core/v8/custom/V8HTMLMediaElementCustom.cpp

Issue 483863003: Use SpecialWrapFor over HTMLMediaElement (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 4 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "config.h"
6 #include "bindings/core/v8/V8HTMLMediaElement.h"
7
8 #include "bindings/core/v8/V8HTMLAudioElement.h"
9 #include "bindings/core/v8/V8HTMLVideoElement.h"
10
11 namespace blink {
12
13 v8::Handle<v8::Object> wrap(HTMLMediaElement* impl, v8::Handle<v8::Object> creat ionContext, v8::Isolate* isolate)
14 {
15 ASSERT(impl);
16
17 if (isHTMLAudioElement(impl))
18 return wrap(toHTMLAudioElement(impl), creationContext, isolate);
19 if (isHTMLVideoElement(impl))
20 return wrap(toHTMLVideoElement(impl), creationContext, isolate);
21
22 ASSERT(!DOMDataStore::containsWrapper<V8HTMLMediaElement>(impl, isolate));
23 return V8HTMLMediaElement::createWrapper(impl, creationContext, isolate);
24 }
25
26 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698