| Index: Source/modules/indexeddb/IDBIndex.cpp
|
| diff --git a/Source/modules/indexeddb/IDBIndex.cpp b/Source/modules/indexeddb/IDBIndex.cpp
|
| index 908959626ffd5109cee4cfb18382df74a06cc4cd..a7759d94bec18429fc30f336396c349f2e02ad07 100644
|
| --- a/Source/modules/indexeddb/IDBIndex.cpp
|
| +++ b/Source/modules/indexeddb/IDBIndex.cpp
|
| @@ -71,7 +71,7 @@ ScriptValue IDBIndex::keyPath(ScriptState* scriptState) const
|
| return idbAnyToScriptValue(scriptState, IDBAny::create(m_metadata.keyPath));
|
| }
|
|
|
| -PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openCursor(ExecutionContext* context, const ScriptValue& range, const String& directionString, ExceptionState& exceptionState)
|
| +PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openCursor(ScriptState* scriptState, const ScriptValue& range, const String& directionString, ExceptionState& exceptionState)
|
| {
|
| IDB_TRACE("IDBIndex::openCursor");
|
| if (isDeleted()) {
|
| @@ -90,7 +90,7 @@ PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openCursor(ExecutionContext* contex
|
| if (exceptionState.hadException())
|
| return nullptr;
|
|
|
| - RefPtrWillBeRawPtr<IDBKeyRange> keyRange = IDBKeyRange::fromScriptValue(context, range, exceptionState);
|
| + RefPtrWillBeRawPtr<IDBKeyRange> keyRange = IDBKeyRange::fromScriptValue(scriptState->executionContext(), range, exceptionState);
|
| if (exceptionState.hadException())
|
| return nullptr;
|
|
|
| @@ -99,18 +99,18 @@ PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openCursor(ExecutionContext* contex
|
| return nullptr;
|
| }
|
|
|
| - return openCursor(context, keyRange.release(), direction);
|
| + return openCursor(scriptState, keyRange.release(), direction);
|
| }
|
|
|
| -PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openCursor(ExecutionContext* context, PassRefPtrWillBeRawPtr<IDBKeyRange> keyRange, WebIDBCursor::Direction direction)
|
| +PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openCursor(ScriptState* scriptState, PassRefPtrWillBeRawPtr<IDBKeyRange> keyRange, WebIDBCursor::Direction direction)
|
| {
|
| - RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(context, IDBAny::create(this), m_transaction.get());
|
| + RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(scriptState, IDBAny::create(this), m_transaction.get());
|
| request->setCursorDetails(IndexedDB::CursorKeyAndValue, direction);
|
| backendDB()->openCursor(m_transaction->id(), m_objectStore->id(), m_metadata.id, keyRange, direction, false, WebIDBDatabase::NormalTask, WebIDBCallbacksImpl::create(request).leakPtr());
|
| return request;
|
| }
|
|
|
| -PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::count(ExecutionContext* context, const ScriptValue& range, ExceptionState& exceptionState)
|
| +PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::count(ScriptState* scriptState, const ScriptValue& range, ExceptionState& exceptionState)
|
| {
|
| IDB_TRACE("IDBIndex::count");
|
| if (isDeleted()) {
|
| @@ -126,7 +126,7 @@ PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::count(ExecutionContext* context, co
|
| return nullptr;
|
| }
|
|
|
| - RefPtrWillBeRawPtr<IDBKeyRange> keyRange = IDBKeyRange::fromScriptValue(context, range, exceptionState);
|
| + RefPtrWillBeRawPtr<IDBKeyRange> keyRange = IDBKeyRange::fromScriptValue(scriptState->executionContext(), range, exceptionState);
|
| if (exceptionState.hadException())
|
| return nullptr;
|
|
|
| @@ -135,12 +135,12 @@ PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::count(ExecutionContext* context, co
|
| return nullptr;
|
| }
|
|
|
| - RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(context, IDBAny::create(this), m_transaction.get());
|
| + RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(scriptState, IDBAny::create(this), m_transaction.get());
|
| backendDB()->count(m_transaction->id(), m_objectStore->id(), m_metadata.id, keyRange.release(), WebIDBCallbacksImpl::create(request).leakPtr());
|
| return request;
|
| }
|
|
|
| -PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openKeyCursor(ExecutionContext* context, const ScriptValue& range, const String& directionString, ExceptionState& exceptionState)
|
| +PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openKeyCursor(ScriptState* scriptState, const ScriptValue& range, const String& directionString, ExceptionState& exceptionState)
|
| {
|
| IDB_TRACE("IDBIndex::openKeyCursor");
|
| if (isDeleted()) {
|
| @@ -159,7 +159,7 @@ PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openKeyCursor(ExecutionContext* con
|
| if (exceptionState.hadException())
|
| return nullptr;
|
|
|
| - RefPtrWillBeRawPtr<IDBKeyRange> keyRange = IDBKeyRange::fromScriptValue(context, range, exceptionState);
|
| + RefPtrWillBeRawPtr<IDBKeyRange> keyRange = IDBKeyRange::fromScriptValue(scriptState->executionContext(), range, exceptionState);
|
| if (exceptionState.hadException())
|
| return nullptr;
|
| if (!backendDB()) {
|
| @@ -167,25 +167,25 @@ PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::openKeyCursor(ExecutionContext* con
|
| return nullptr;
|
| }
|
|
|
| - RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(context, IDBAny::create(this), m_transaction.get());
|
| + RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(scriptState, IDBAny::create(this), m_transaction.get());
|
| request->setCursorDetails(IndexedDB::CursorKeyOnly, direction);
|
| backendDB()->openCursor(m_transaction->id(), m_objectStore->id(), m_metadata.id, keyRange.release(), direction, true, WebIDBDatabase::NormalTask, WebIDBCallbacksImpl::create(request).leakPtr());
|
| return request;
|
| }
|
|
|
| -PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::get(ExecutionContext* context, const ScriptValue& key, ExceptionState& exceptionState)
|
| +PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::get(ScriptState* scriptState, const ScriptValue& key, ExceptionState& exceptionState)
|
| {
|
| IDB_TRACE("IDBIndex::get");
|
| - return getInternal(context, key, exceptionState, false);
|
| + return getInternal(scriptState, key, exceptionState, false);
|
| }
|
|
|
| -PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::getKey(ExecutionContext* context, const ScriptValue& key, ExceptionState& exceptionState)
|
| +PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::getKey(ScriptState* scriptState, const ScriptValue& key, ExceptionState& exceptionState)
|
| {
|
| IDB_TRACE("IDBIndex::getKey");
|
| - return getInternal(context, key, exceptionState, true);
|
| + return getInternal(scriptState, key, exceptionState, true);
|
| }
|
|
|
| -PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::getInternal(ExecutionContext* context, const ScriptValue& key, ExceptionState& exceptionState, bool keyOnly)
|
| +PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::getInternal(ScriptState* scriptState, const ScriptValue& key, ExceptionState& exceptionState, bool keyOnly)
|
| {
|
| if (isDeleted()) {
|
| exceptionState.throwDOMException(InvalidStateError, IDBDatabase::indexDeletedErrorMessage);
|
| @@ -200,7 +200,7 @@ PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::getInternal(ExecutionContext* conte
|
| return nullptr;
|
| }
|
|
|
| - RefPtrWillBeRawPtr<IDBKeyRange> keyRange = IDBKeyRange::fromScriptValue(context, key, exceptionState);
|
| + RefPtrWillBeRawPtr<IDBKeyRange> keyRange = IDBKeyRange::fromScriptValue(scriptState->executionContext(), key, exceptionState);
|
| if (exceptionState.hadException())
|
| return nullptr;
|
| if (!keyRange) {
|
| @@ -212,7 +212,7 @@ PassRefPtrWillBeRawPtr<IDBRequest> IDBIndex::getInternal(ExecutionContext* conte
|
| return nullptr;
|
| }
|
|
|
| - RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(context, IDBAny::create(this), m_transaction.get());
|
| + RefPtrWillBeRawPtr<IDBRequest> request = IDBRequest::create(scriptState, IDBAny::create(this), m_transaction.get());
|
| backendDB()->get(m_transaction->id(), m_objectStore->id(), m_metadata.id, keyRange.release(), keyOnly, WebIDBCallbacksImpl::create(request).leakPtr());
|
| return request;
|
| }
|
|
|