Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(15)

Unified Diff: public/platform/WebCrypto.h

Issue 23338006: Cleanup: remove WebCryptoResultPrivate from blink API. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove extra newline Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/modules/modules.gypi ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: public/platform/WebCrypto.h
diff --git a/public/platform/WebCrypto.h b/public/platform/WebCrypto.h
index 6b6f0a06c4b54a1d389248e5c0f556a0848ad553..2eb28fc4122c47d652a6bb80b2c4385557188ac1 100644
--- a/public/platform/WebCrypto.h
+++ b/public/platform/WebCrypto.h
@@ -35,32 +35,19 @@
#include "WebCryptoKey.h"
#include "WebPrivatePtr.h"
+namespace WebCore { class CryptoResult; }
+
+#if WEBKIT_IMPLEMENTATION
+namespace WTF { template <typename T> class PassRefPtr; }
+#endif
+
namespace WebKit {
class WebArrayBuffer;
class WebCryptoOperation;
-class WebCryptoResultPrivate {
-public:
- virtual void ref() = 0;
- virtual void deref() = 0;
-
- virtual void completeWithError() = 0;
- virtual void completeWithBuffer(const WebArrayBuffer&) = 0;
- virtual void completeWithBoolean(bool) = 0;
- virtual void completeWithKey(const WebCryptoKey&) = 0;
-
-protected:
- virtual ~WebCryptoResultPrivate() { }
-};
-
class WebCryptoResult {
public:
- explicit WebCryptoResult(WebCryptoResultPrivate* impl)
- {
- assign(impl);
- }
-
WebCryptoResult(const WebCryptoResult& o)
{
assign(o);
@@ -83,12 +70,15 @@ public:
WEBKIT_EXPORT void completeWithBoolean(bool);
WEBKIT_EXPORT void completeWithKey(const WebCryptoKey&);
+#if WEBKIT_IMPLEMENTATION
+ explicit WebCryptoResult(const WTF::PassRefPtr<WebCore::CryptoResult>&);
+#endif
+
private:
WEBKIT_EXPORT void reset();
WEBKIT_EXPORT void assign(const WebCryptoResult&);
- WEBKIT_EXPORT void assign(WebCryptoResultPrivate*);
- WebPrivatePtr<WebCryptoResultPrivate> m_impl;
+ WebPrivatePtr<WebCore::CryptoResult> m_impl;
};
class WebCrypto {
« no previous file with comments | « Source/modules/modules.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698