| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 #include "core/dom/Document.h" | 35 #include "core/dom/Document.h" |
| 36 #include "core/dom/ExceptionCode.h" | 36 #include "core/dom/ExceptionCode.h" |
| 37 #include "core/dom/ExecutionContext.h" | 37 #include "core/dom/ExecutionContext.h" |
| 38 #include "modules/quota/DeprecatedStorageQuota.h" | 38 #include "modules/quota/DeprecatedStorageQuota.h" |
| 39 #include "modules/quota/StorageErrorCallback.h" | 39 #include "modules/quota/StorageErrorCallback.h" |
| 40 #include "modules/quota/StorageQuotaCallback.h" | 40 #include "modules/quota/StorageQuotaCallback.h" |
| 41 #include "modules/quota/StorageUsageCallback.h" | 41 #include "modules/quota/StorageUsageCallback.h" |
| 42 | 42 |
| 43 namespace WebCore { | 43 namespace WebCore { |
| 44 | 44 |
| 45 DEFINE_GC_INFO(DeprecatedStorageInfo); | |
| 46 | |
| 47 DeprecatedStorageInfo::DeprecatedStorageInfo() | 45 DeprecatedStorageInfo::DeprecatedStorageInfo() |
| 48 { | 46 { |
| 49 ScriptWrappable::init(this); | 47 ScriptWrappable::init(this); |
| 50 } | 48 } |
| 51 | 49 |
| 52 DeprecatedStorageInfo::~DeprecatedStorageInfo() | 50 DeprecatedStorageInfo::~DeprecatedStorageInfo() |
| 53 { | 51 { |
| 54 } | 52 } |
| 55 | 53 |
| 56 void DeprecatedStorageInfo::queryUsageAndQuota(ExecutionContext* executionContex
t, int storageType, PassOwnPtr<StorageUsageCallback> successCallback, PassOwnPtr
<StorageErrorCallback> errorCallback) | 54 void DeprecatedStorageInfo::queryUsageAndQuota(ExecutionContext* executionContex
t, int storageType, PassOwnPtr<StorageUsageCallback> successCallback, PassOwnPtr
<StorageErrorCallback> errorCallback) |
| (...skipping 28 matching lines...) Expand all Loading... |
| 85 m_temporaryStorage = DeprecatedStorageQuota::create(DeprecatedStorag
eQuota::Temporary); | 83 m_temporaryStorage = DeprecatedStorageQuota::create(DeprecatedStorag
eQuota::Temporary); |
| 86 return m_temporaryStorage.get(); | 84 return m_temporaryStorage.get(); |
| 87 case PERSISTENT: | 85 case PERSISTENT: |
| 88 if (!m_persistentStorage) | 86 if (!m_persistentStorage) |
| 89 m_persistentStorage = DeprecatedStorageQuota::create(DeprecatedStora
geQuota::Persistent); | 87 m_persistentStorage = DeprecatedStorageQuota::create(DeprecatedStora
geQuota::Persistent); |
| 90 return m_persistentStorage.get(); | 88 return m_persistentStorage.get(); |
| 91 } | 89 } |
| 92 return 0; | 90 return 0; |
| 93 } | 91 } |
| 94 | 92 |
| 95 void DeprecatedStorageInfo::trace(Visitor* visitor) | |
| 96 { | |
| 97 visitor->trace(m_temporaryStorage); | |
| 98 visitor->trace(m_persistentStorage); | |
| 99 } | |
| 100 | |
| 101 } // namespace WebCore | 93 } // namespace WebCore |
| OLD | NEW |