From af6588f8d723931a298c995fa97259bb7f7deb55 Mon Sep 17 00:00:00 2001 From: Zeno Albisser Date: Fri, 5 Dec 2014 15:04:29 +0100 Subject: BASELINE: Update chromium to 40.0.2214.28 and ninja to 1.5.3. Change-Id: I759465284fd64d59ad120219cbe257f7402c4181 Reviewed-by: Andras Becsi --- .../browser/indexed_db/indexed_db_database.h | 48 ++++++++++------------ 1 file changed, 21 insertions(+), 27 deletions(-) (limited to 'chromium/content/browser/indexed_db/indexed_db_database.h') diff --git a/chromium/content/browser/indexed_db/indexed_db_database.h b/chromium/content/browser/indexed_db/indexed_db_database.h index 63a438a4bb6..bcde7190c50 100644 --- a/chromium/content/browser/indexed_db/indexed_db_database.h +++ b/chromium/content/browser/indexed_db/indexed_db_database.h @@ -20,6 +20,7 @@ #include "content/browser/indexed_db/indexed_db_pending_connection.h" #include "content/browser/indexed_db/indexed_db_transaction_coordinator.h" #include "content/browser/indexed_db/list_set.h" +#include "third_party/WebKit/public/platform/WebIDBTypes.h" #include "url/gurl.h" namespace content { @@ -37,17 +38,6 @@ struct IndexedDBValue; class CONTENT_EXPORT IndexedDBDatabase : NON_EXPORTED_BASE(public base::RefCounted) { public: - enum TaskType { - NORMAL_TASK = 0, - PREEMPTIVE_TASK - }; - - enum PutMode { - ADD_OR_UPDATE, - ADD_ONLY, - CURSOR_UPDATE - }; - // An index and corresponding set of keys typedef std::pair > IndexKeys; @@ -91,10 +81,15 @@ class CONTENT_EXPORT IndexedDBDatabase void CreateTransaction(int64 transaction_id, IndexedDBConnection* connection, const std::vector& object_store_ids, - uint16 mode); + blink::WebIDBTransactionMode mode); void Close(IndexedDBConnection* connection, bool forced); void ForceClose(); + // Ack that one of the connections notified with a "versionchange" event did + // not promptly close. Therefore a "blocked" event should be fired at the + // pending connection. + void VersionChangeIgnored(); + void Commit(int64 transaction_id); void Abort(int64 transaction_id); void Abort(int64 transaction_id, const IndexedDBDatabaseError& error); @@ -119,7 +114,7 @@ class CONTENT_EXPORT IndexedDBDatabase void TransactionFinished(IndexedDBTransaction* transaction, bool committed); // Called by transactions to report failure committing to the backing store. - void TransactionCommitFailed(); + void TransactionCommitFailed(const leveldb::Status& status); void Get(int64 transaction_id, int64 object_store_id, @@ -130,9 +125,9 @@ class CONTENT_EXPORT IndexedDBDatabase void Put(int64 transaction_id, int64 object_store_id, IndexedDBValue* value, - ScopedVector* handles, + ScopedVector* handles, scoped_ptr key, - PutMode mode, + blink::WebIDBPutMode mode, scoped_refptr callbacks, const std::vector& index_keys); void SetIndexKeys(int64 transaction_id, @@ -146,9 +141,9 @@ class CONTENT_EXPORT IndexedDBDatabase int64 object_store_id, int64 index_id, scoped_ptr key_range, - indexed_db::CursorDirection, + blink::WebIDBCursorDirection, bool key_only, - TaskType task_type, + blink::WebIDBTaskType task_type, scoped_refptr callbacks); void Count(int64 transaction_id, int64 object_store_id, @@ -229,6 +224,15 @@ class CONTENT_EXPORT IndexedDBDatabase private: friend class base::RefCounted; + class PendingDeleteCall; + class PendingSuccessCall; + class PendingUpgradeCall; + + typedef std::map TransactionMap; + typedef std::list PendingOpenCallList; + typedef std::list PendingDeleteCallList; + typedef list_set ConnectionSet; + IndexedDBDatabase(const base::string16& name, IndexedDBBackingStore* backing_store, IndexedDBFactory* factory, @@ -273,22 +277,12 @@ class CONTENT_EXPORT IndexedDBDatabase IndexedDBTransactionCoordinator transaction_coordinator_; - typedef std::map TransactionMap; TransactionMap transactions_; - - typedef std::list PendingOpenCallList; PendingOpenCallList pending_open_calls_; - - class PendingUpgradeCall; scoped_ptr pending_run_version_change_transaction_call_; - class PendingSuccessCall; scoped_ptr pending_second_half_open_; - - class PendingDeleteCall; - typedef std::list PendingDeleteCallList; PendingDeleteCallList pending_delete_calls_; - typedef list_set ConnectionSet; ConnectionSet connections_; DISALLOW_COPY_AND_ASSIGN(IndexedDBDatabase); -- cgit v1.2.1