| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Apple Inc. All rights reserved. | 2 * Copyright (C) 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 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 #include "modules/webdatabase/SQLTransactionClient.h" | 46 #include "modules/webdatabase/SQLTransactionClient.h" |
| 47 #include "modules/webdatabase/SQLTransactionCoordinator.h" | 47 #include "modules/webdatabase/SQLTransactionCoordinator.h" |
| 48 #include "modules/webdatabase/SQLTransactionErrorCallback.h" | 48 #include "modules/webdatabase/SQLTransactionErrorCallback.h" |
| 49 #include "modules/webdatabase/sqlite/SQLiteStatement.h" | 49 #include "modules/webdatabase/sqlite/SQLiteStatement.h" |
| 50 #include "modules/webdatabase/sqlite/SQLiteTransaction.h" | 50 #include "modules/webdatabase/sqlite/SQLiteTransaction.h" |
| 51 #include "platform/Logging.h" | 51 #include "platform/Logging.h" |
| 52 #include "platform/heap/SafePoint.h" | 52 #include "platform/heap/SafePoint.h" |
| 53 #include "platform/weborigin/DatabaseIdentifier.h" | 53 #include "platform/weborigin/DatabaseIdentifier.h" |
| 54 #include "public/platform/Platform.h" | 54 #include "public/platform/Platform.h" |
| 55 #include "public/platform/WebDatabaseObserver.h" | 55 #include "public/platform/WebDatabaseObserver.h" |
| 56 #include "wtf/CurrentTime.h" |
| 56 | 57 |
| 57 // Registering "opened" databases with the DatabaseTracker | 58 // Registering "opened" databases with the DatabaseTracker |
| 58 // ======================================================= | 59 // ======================================================= |
| 59 // The DatabaseTracker maintains a list of databases that have been | 60 // The DatabaseTracker maintains a list of databases that have been |
| 60 // "opened" so that the client can call interrupt or delete on every database | 61 // "opened" so that the client can call interrupt or delete on every database |
| 61 // associated with a DatabaseContext. | 62 // associated with a DatabaseContext. |
| 62 // | 63 // |
| 63 // We will only call DatabaseTracker::addOpenDatabase() to add the database | 64 // We will only call DatabaseTracker::addOpenDatabase() to add the database |
| 64 // to the tracker as opened when we've succeeded in opening the database, | 65 // to the tracker as opened when we've succeeded in opening the database, |
| 65 // and will set m_opened to true. Similarly, we only call | 66 // and will set m_opened to true. Similarly, we only call |
| (...skipping 829 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 895 SecurityOrigin* Database::securityOrigin() const | 896 SecurityOrigin* Database::securityOrigin() const |
| 896 { | 897 { |
| 897 if (executionContext()->isContextThread()) | 898 if (executionContext()->isContextThread()) |
| 898 return m_contextThreadSecurityOrigin.get(); | 899 return m_contextThreadSecurityOrigin.get(); |
| 899 if (databaseContext()->databaseThread()->isDatabaseThread()) | 900 if (databaseContext()->databaseThread()->isDatabaseThread()) |
| 900 return m_databaseThreadSecurityOrigin.get(); | 901 return m_databaseThreadSecurityOrigin.get(); |
| 901 return 0; | 902 return 0; |
| 902 } | 903 } |
| 903 | 904 |
| 904 } // namespace blink | 905 } // namespace blink |
| OLD | NEW |