| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008, 2013 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008, 2013 Apple 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 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 145 } | 145 } |
| 146 | 146 |
| 147 bool DatabaseThread::isDatabaseOpen(Database* database) | 147 bool DatabaseThread::isDatabaseOpen(Database* database) |
| 148 { | 148 { |
| 149 ASSERT(isDatabaseThread()); | 149 ASSERT(isDatabaseThread()); |
| 150 ASSERT(database); | 150 ASSERT(database); |
| 151 MutexLocker lock(m_terminationRequestedMutex); | 151 MutexLocker lock(m_terminationRequestedMutex); |
| 152 return !m_terminationRequested && m_openDatabaseSet.contains(database); | 152 return !m_terminationRequested && m_openDatabaseSet.contains(database); |
| 153 } | 153 } |
| 154 | 154 |
| 155 SQLTransactionCoordinator* DatabaseThread::transactionCoordinator() const | |
| 156 { | |
| 157 return m_transactionCoordinator.get(); | |
| 158 } | |
| 159 | |
| 160 void DatabaseThread::scheduleTask(PassOwnPtr<DatabaseTask> task) | 155 void DatabaseThread::scheduleTask(PassOwnPtr<DatabaseTask> task) |
| 161 { | 156 { |
| 162 ASSERT(m_thread); | 157 ASSERT(m_thread); |
| 163 ASSERT(!terminationRequested()); | 158 ASSERT(!terminationRequested()); |
| 164 // WebThread takes ownership of the task. | 159 // WebThread takes ownership of the task. |
| 165 m_thread->postTask(BLINK_FROM_HERE, new Task(threadSafeBind(&DatabaseTask::r
un, task))); | 160 m_thread->postTask(BLINK_FROM_HERE, new Task(threadSafeBind(&DatabaseTask::r
un, task))); |
| 166 } | 161 } |
| 167 | 162 |
| 168 } // namespace blink | 163 } // namespace blink |
| OLD | NEW |