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

Unified Diff: Source/bindings/v8/custom/V8StorageCustom.cpp

Issue 15899009: Support indexed setter generation (Closed) Base URL: https://chromium.googlesource.com/chromium/blink@master
Patch Set: rebased Created 7 years, 7 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/v8/custom/V8HTMLSelectElementCustom.cpp ('k') | Source/core/html/HTMLOptionsCollection.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/v8/custom/V8StorageCustom.cpp
diff --git a/Source/bindings/v8/custom/V8StorageCustom.cpp b/Source/bindings/v8/custom/V8StorageCustom.cpp
index cff6e1dd41a749d4d5d75411e2baea5d92453d81..c4dcbc27bb9560dc359a67211ceec3aff54e0558 100644
--- a/Source/bindings/v8/custom/V8StorageCustom.cpp
+++ b/Source/bindings/v8/custom/V8StorageCustom.cpp
@@ -81,31 +81,4 @@ v8::Handle<v8::Integer> V8Storage::namedPropertyQuery(v8::Local<v8::String> v8Na
return v8Integer(0, info.GetIsolate());
}
-static v8::Handle<v8::Value> storageSetter(v8::Local<v8::String> v8Name, v8::Local<v8::Value> v8Value, const v8::AccessorInfo& info)
-{
- Storage* storage = V8Storage::toNative(info.Holder());
- String name = toWebCoreString(v8Name);
- String value = toWebCoreString(v8Value);
-
- // Silently ignore length (rather than letting the bindings raise an exception).
- if (name == "length")
- return v8Value;
-
- if (!info.Holder()->GetRealNamedPropertyInPrototypeChain(v8Name).IsEmpty())
- return v8Undefined();
-
- ExceptionCode ec = 0;
- storage->setItem(name, value, ec);
- if (ec)
- return setDOMException(ec, info.GetIsolate());
-
- return v8Value;
-}
-
-v8::Handle<v8::Value> V8Storage::indexedPropertySetter(uint32_t index, v8::Local<v8::Value> value, const v8::AccessorInfo& info)
-{
- v8::Handle<v8::Integer> indexV8 = v8Integer(index, info.GetIsolate());
- return storageSetter(indexV8->ToString(), value, info);
-}
-
} // namespace WebCore
« no previous file with comments | « Source/bindings/v8/custom/V8HTMLSelectElementCustom.cpp ('k') | Source/core/html/HTMLOptionsCollection.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698