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

Unified Diff: Source/bindings/core/v8/custom/V8HTMLOptionsCollectionCustom.cpp

Issue 716773002: Use union types for HTMLSelectElement.add()'s arguments (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: added FIXME Created 6 years, 1 month 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 | « LayoutTests/fast/js/select-options-add-expected.txt ('k') | Source/bindings/scripts/v8_union.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/core/v8/custom/V8HTMLOptionsCollectionCustom.cpp
diff --git a/Source/bindings/core/v8/custom/V8HTMLOptionsCollectionCustom.cpp b/Source/bindings/core/v8/custom/V8HTMLOptionsCollectionCustom.cpp
index 1c4a6ec6d7e77b64abd6f39448f805c77b767787..b54dbc85649782eaa678c6293ac9836df2c10169 100644
--- a/Source/bindings/core/v8/custom/V8HTMLOptionsCollectionCustom.cpp
+++ b/Source/bindings/core/v8/custom/V8HTMLOptionsCollectionCustom.cpp
@@ -43,29 +43,6 @@
namespace blink {
-void V8HTMLOptionsCollection::addMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& info)
-{
- ExceptionState exceptionState(ExceptionState::ExecutionContext, "add", "HTMLOptionsCollection", info.Holder(), info.GetIsolate());
- if (!V8HTMLOptionElement::hasInstance(info[0], info.GetIsolate())) {
- exceptionState.throwTypeError("The element provided was not an HTMLOptionElement.");
- } else {
- HTMLOptionsCollection* impl = V8HTMLOptionsCollection::toImpl(info.Holder());
- HTMLOptionElement* option = V8HTMLOptionElement::toImpl(v8::Handle<v8::Object>(v8::Handle<v8::Object>::Cast(info[0])));
-
- if (info.Length() < 2) {
- impl->add(option, exceptionState);
- } else {
- int index = toInt32(info[1], exceptionState);
- if (exceptionState.throwIfNeeded())
- return;
-
- impl->add(option, index, exceptionState);
- }
- }
-
- exceptionState.throwIfNeeded();
-}
-
void V8HTMLOptionsCollection::lengthAttributeSetterCustom(v8::Local<v8::Value> value, const v8::PropertyCallbackInfo<void>& info)
{
HTMLOptionsCollection* impl = V8HTMLOptionsCollection::toImpl(info.Holder());
« no previous file with comments | « LayoutTests/fast/js/select-options-add-expected.txt ('k') | Source/bindings/scripts/v8_union.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698