OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 , m_id(id) | 64 , m_id(id) |
65 , m_database(db) | 65 , m_database(db) |
66 , m_objectStoreNames(objectStoreNames) | 66 , m_objectStoreNames(objectStoreNames) |
67 , m_openDBRequest(openDBRequest) | 67 , m_openDBRequest(openDBRequest) |
68 , m_mode(mode) | 68 , m_mode(mode) |
69 , m_state(Active) | 69 , m_state(Active) |
70 , m_hasPendingActivity(true) | 70 , m_hasPendingActivity(true) |
71 , m_contextStopped(false) | 71 , m_contextStopped(false) |
72 , m_previousMetadata(previousMetadata) | 72 , m_previousMetadata(previousMetadata) |
73 { | 73 { |
74 ScriptWrappable::init(this); | |
75 if (mode == WebIDBTransactionModeVersionChange) { | 74 if (mode == WebIDBTransactionModeVersionChange) { |
76 // Not active until the callback. | 75 // Not active until the callback. |
77 m_state = Inactive; | 76 m_state = Inactive; |
78 } | 77 } |
79 | 78 |
80 if (m_state == Active) | 79 if (m_state == Active) |
81 IDBPendingTransactionMonitor::from(*context).addNewTransaction(*this); | 80 IDBPendingTransactionMonitor::from(*context).addNewTransaction(*this); |
82 m_database->transactionCreated(this); | 81 m_database->transactionCreated(this); |
83 } | 82 } |
84 | 83 |
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
373 event->setTarget(this); | 372 event->setTarget(this); |
374 eventQueue->enqueueEvent(event); | 373 eventQueue->enqueueEvent(event); |
375 } | 374 } |
376 | 375 |
377 WebIDBDatabase* IDBTransaction::backendDB() const | 376 WebIDBDatabase* IDBTransaction::backendDB() const |
378 { | 377 { |
379 return m_database->backend(); | 378 return m_database->backend(); |
380 } | 379 } |
381 | 380 |
382 } // namespace blink | 381 } // namespace blink |
OLD | NEW |