Ejemplo n.º 1
0
void IDBOpenDBRequest::fireErrorAfterVersionChangeAbort()
{
    LOG(IndexedDB, "IDBOpenDBRequest::fireErrorAfterVersionChangeAbort()");

    ASSERT(hasPendingActivity());

    IDBError idbError(IDBDatabaseException::AbortError);
    m_domError = DOMError::create(idbError.name());

    m_transaction->addRequest(*this);
    enqueueEvent(Event::create(eventNames().errorEvent, true, true));
}
Ejemplo n.º 2
0
void IDBOpenDBRequest::fireErrorAfterVersionChangeCompletion()
{
    LOG(IndexedDB, "IDBOpenDBRequest::fireErrorAfterVersionChangeCompletion() - %s", resourceIdentifier().loggingString().utf8().data());

    ASSERT(currentThread() == originThreadID());
    ASSERT(hasPendingActivity());

    IDBError idbError(IDBDatabaseException::AbortError);
    m_domError = DOMError::create(idbError.name(), idbError.message());
    setResultToUndefined();

    m_transaction->addRequest(*this);
    enqueueEvent(IDBRequestCompletionEvent::create(eventNames().errorEvent, true, true, *this));
}