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

Unified Diff: third_party/WebKit/Source/modules/indexeddb/IDBObserverChanges.cpp

Issue 2031113002: IndexedDB Observers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: expected files updated Created 4 years, 6 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
Index: third_party/WebKit/Source/modules/indexeddb/IDBObserverChanges.cpp
diff --git a/third_party/WebKit/Source/modules/indexeddb/IDBObserverChanges.cpp b/third_party/WebKit/Source/modules/indexeddb/IDBObserverChanges.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..f8a03b4deb8d024c759ea44367da82ee3c81d655
--- /dev/null
+++ b/third_party/WebKit/Source/modules/indexeddb/IDBObserverChanges.cpp
@@ -0,0 +1,41 @@
+// Copyright 2016 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 "modules/indexeddb/IDBObserverChanges.h"
+
+#include "bindings/core/v8/ExceptionState.h"
+#include "bindings/core/v8/ScriptState.h"
+#include "bindings/modules/v8/ToV8ForModules.h"
+#include "bindings/modules/v8/V8BindingForModules.h"
+#include "modules/indexeddb/IDBAny.h"
+
+namespace blink {
+
+IDBObserverChanges::~IDBObserverChanges() {}
+
+ScriptValue IDBObserverChanges::records(ScriptState* scriptState)
+{
+ return ScriptValue::from(scriptState, m_records);
+}
+
+IDBObserverChanges* IDBObserverChanges::create(IDBDatabase* database, IDBTransaction* transaction, IDBAny* records)
+{
+ return new IDBObserverChanges(database, transaction, records);
+}
+
+IDBObserverChanges::IDBObserverChanges(IDBDatabase* database, IDBTransaction* transaction, IDBAny* records)
+ : m_database(database)
+ , m_transaction(transaction)
+ , m_records(records)
+{
+}
+
+DEFINE_TRACE(IDBObserverChanges)
+{
+ visitor->trace(m_database);
+ visitor->trace(m_transaction);
+ visitor->trace(m_records);
+}
+
+} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698