Index: content/common/indexed_db/indexed_db_dispatcher.cc |
diff --git a/content/common/indexed_db/indexed_db_dispatcher.cc b/content/common/indexed_db/indexed_db_dispatcher.cc |
index b725a7d7d400d3a7e9341bd69f2628320bd9c826..cc5d18caa9defa5ebf31dc70b4648be3527f9548 100644 |
--- a/content/common/indexed_db/indexed_db_dispatcher.cc |
+++ b/content/common/indexed_db/indexed_db_dispatcher.cc |
@@ -80,6 +80,8 @@ void IndexedDBDispatcher::OnMessageReceived(const IPC::Message& msg) { |
IPC_BEGIN_MESSAGE_MAP(IndexedDBDispatcher, msg) |
IPC_MESSAGE_HANDLER(IndexedDBMsg_CallbacksSuccessIDBCursor, |
OnSuccessOpenCursor) |
+ IPC_MESSAGE_HANDLER(IndexedDBMsg_CallbacksSuccessCursorAdvance, |
+ OnSuccessCursorContinue) |
IPC_MESSAGE_HANDLER(IndexedDBMsg_CallbacksSuccessCursorContinue, |
OnSuccessCursorContinue) |
IPC_MESSAGE_HANDLER(IndexedDBMsg_CallbacksSuccessCursorPrefetch, |
@@ -136,6 +138,23 @@ void IndexedDBDispatcher::RequestIDBCursorUpdate( |
pending_callbacks_.Remove(response_id); |
} |
+void IndexedDBDispatcher::RequestIDBCursorAdvance( |
+ unsigned long count, |
+ WebIDBCallbacks* callbacks_ptr, |
+ int32 idb_cursor_id, |
+ WebExceptionCode* ec) { |
+ // Reset all cursor prefetch caches except for this cursor. |
+ ResetCursorPrefetchCaches(idb_cursor_id); |
+ |
+ scoped_ptr<WebIDBCallbacks> callbacks(callbacks_ptr); |
+ |
+ int32 response_id = pending_callbacks_.Add(callbacks.release()); |
+ Send(new IndexedDBHostMsg_CursorAdvance(idb_cursor_id, CurrentWorkerId(), |
+ response_id, count, ec)); |
+ if (*ec) |
+ pending_callbacks_.Remove(response_id); |
+} |
+ |
void IndexedDBDispatcher::RequestIDBCursorContinue( |
const IndexedDBKey& key, |
WebIDBCallbacks* callbacks_ptr, |