| Index: Source/modules/crypto/DOMWindowCrypto.cpp
|
| diff --git a/Source/modules/quota/DOMWindowQuota.cpp b/Source/modules/crypto/DOMWindowCrypto.cpp
|
| similarity index 67%
|
| copy from Source/modules/quota/DOMWindowQuota.cpp
|
| copy to Source/modules/crypto/DOMWindowCrypto.cpp
|
| index c71a279e87ce6d855734c070666c114356c39746..237c298876451ce2a910a4969e8e153aaa23ff93 100644
|
| --- a/Source/modules/quota/DOMWindowQuota.cpp
|
| +++ b/Source/modules/crypto/DOMWindowCrypto.cpp
|
| @@ -1,5 +1,5 @@
|
| /*
|
| - * Copyright (C) 2012 Google Inc. All rights reserved.
|
| + * Copyright (C) 2013 Google Inc. All rights reserved.
|
| *
|
| * Redistribution and use in source and binary forms, with or without
|
| * modification, are permitted provided that the following conditions are
|
| @@ -29,53 +29,50 @@
|
| */
|
|
|
| #include "config.h"
|
| -#include "modules/quota/DOMWindowQuota.h"
|
| +#include "modules/crypto/DOMWindowCrypto.h"
|
|
|
| -#include "core/dom/Document.h"
|
| #include "core/page/DOMWindow.h"
|
| #include "core/page/Frame.h"
|
| -#include "core/page/PageConsole.h"
|
| -#include "modules/quota/StorageInfo.h"
|
| -#include "wtf/PassRefPtr.h"
|
| +#include "modules/crypto/Crypto.h"
|
|
|
| namespace WebCore {
|
|
|
| -DOMWindowQuota::DOMWindowQuota(DOMWindow* window)
|
| +DOMWindowCrypto::DOMWindowCrypto(DOMWindow* window)
|
| : DOMWindowProperty(window->frame())
|
| {
|
| }
|
|
|
| -DOMWindowQuota::~DOMWindowQuota()
|
| +DOMWindowCrypto::~DOMWindowCrypto()
|
| {
|
| }
|
|
|
| -const char* DOMWindowQuota::supplementName()
|
| +const char* DOMWindowCrypto::supplementName()
|
| {
|
| - return "DOMWindowQuota";
|
| + return "DOMWindowCrypto";
|
| }
|
|
|
| // static
|
| -DOMWindowQuota* DOMWindowQuota::from(DOMWindow* window)
|
| +DOMWindowCrypto* DOMWindowCrypto::from(DOMWindow* window)
|
| {
|
| - DOMWindowQuota* supplement = static_cast<DOMWindowQuota*>(Supplement<DOMWindow>::from(window, supplementName()));
|
| + DOMWindowCrypto* supplement = static_cast<DOMWindowCrypto*>(Supplement<DOMWindow>::from(window, supplementName()));
|
| if (!supplement) {
|
| - supplement = new DOMWindowQuota(window);
|
| + supplement = new DOMWindowCrypto(window);
|
| provideTo(window, supplementName(), adoptPtr(supplement));
|
| }
|
| return supplement;
|
| }
|
|
|
| // static
|
| -StorageInfo* DOMWindowQuota::webkitStorageInfo(DOMWindow* window)
|
| +Crypto* DOMWindowCrypto::crypto(DOMWindow* window)
|
| {
|
| - return DOMWindowQuota::from(window)->webkitStorageInfo();
|
| + return DOMWindowCrypto::from(window)->crypto();
|
| }
|
|
|
| -StorageInfo* DOMWindowQuota::webkitStorageInfo() const
|
| +Crypto* DOMWindowCrypto::crypto() const
|
| {
|
| - if (!m_storageInfo && frame())
|
| - m_storageInfo = StorageInfo::create();
|
| - return m_storageInfo.get();
|
| + if (!m_crypto && frame())
|
| + m_crypto = Crypto::create();
|
| + return m_crypto.get();
|
| }
|
|
|
| } // namespace WebCore
|
|
|