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

Unified Diff: content/browser/in_process_webkit/indexed_db_callbacks.h

Issue 10830028: IndexedDB: Send cursor data along with success messages (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comment tweaks and rebase Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/browser/in_process_webkit/indexed_db_callbacks.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/in_process_webkit/indexed_db_callbacks.h
diff --git a/content/browser/in_process_webkit/indexed_db_callbacks.h b/content/browser/in_process_webkit/indexed_db_callbacks.h
index 5d826c2001e40a7d00a6b3708017abfd29504a8d..69abbc1990322a542ef2fa5c9b73f579e759d955 100644
--- a/content/browser/in_process_webkit/indexed_db_callbacks.h
+++ b/content/browser/in_process_webkit/indexed_db_callbacks.h
@@ -105,11 +105,22 @@ class IndexedDBCallbacks : public IndexedDBCallbacksBase {
DISALLOW_IMPLICIT_CONSTRUCTORS(IndexedDBCallbacks);
};
+// TODO(jsbell): Remove this preamble comment after WK92278 rolls.
+// Pre WK92278:
// WebIDBCursor uses onSuccess(WebIDBCursor*) when a cursor has been opened,
// onSuccessWithContinuation() when a continue() call has succeeded, or
// onSuccess(SerializedScriptValue::nullValue()) to indicate it does
// not contain any data, i.e., there is no key within the key range,
// or it has reached the end.
+// Post WK92278:
+// WebIDBCursor uses:
+// * onSuccess(WebIDBCursor*, WebIDBKey, WebIDBKey, SerializedScriptValue)
+// when an openCursor()/openKeyCursor() call has succeeded,
+// * onSuccess(WebIDBKey, WebIDBKey, SerializedScriptValue)
+// when an advance()/continue() call has succeeded, or
+// * onSuccess(SerializedScriptValue::nullValue())
+// to indicate it does not contain any data, i.e., there is no key within
+// the key range, or it has reached the end.
template <>
class IndexedDBCallbacks<WebKit::WebIDBCursor>
: public IndexedDBCallbacksBase {
@@ -122,8 +133,17 @@ class IndexedDBCallbacks<WebKit::WebIDBCursor>
: IndexedDBCallbacksBase(dispatcher_host, thread_id, response_id),
cursor_id_(cursor_id) { }
+ // TODO(jsbell): Remove this after WK92278 rolls.
virtual void onSuccess(WebKit::WebIDBCursor* idb_object);
+ virtual void onSuccess(WebKit::WebIDBCursor* idb_object,
+ const WebKit::WebIDBKey& key,
+ const WebKit::WebIDBKey& primaryKey,
+ const WebKit::WebSerializedScriptValue& value);
+ virtual void onSuccess(const WebKit::WebIDBKey& key,
+ const WebKit::WebIDBKey& primaryKey,
+ const WebKit::WebSerializedScriptValue& value);
virtual void onSuccess(const WebKit::WebSerializedScriptValue& value);
+ // TODO(jsbell): Remove this after WK92278 rolls.
virtual void onSuccessWithContinuation();
virtual void onSuccessWithPrefetch(
const WebKit::WebVector<WebKit::WebIDBKey>& keys,
« no previous file with comments | « no previous file | content/browser/in_process_webkit/indexed_db_callbacks.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698