| Index: content/renderer/media/webcontentdecryptionmodule_impl.h
|
| diff --git a/content/renderer/media/webcontentdecryptionmodule_impl.h b/content/renderer/media/webcontentdecryptionmodule_impl.h
|
| index 2619e5610b3eeea3a0ca232bd018536aac3a85e5..1f4eb4439e26393d81b1e3b92dacd3022de47d38 100644
|
| --- a/content/renderer/media/webcontentdecryptionmodule_impl.h
|
| +++ b/content/renderer/media/webcontentdecryptionmodule_impl.h
|
| @@ -9,7 +9,9 @@
|
|
|
| #include "base/memory/ref_counted.h"
|
| #include "base/memory/scoped_ptr.h"
|
| +#include "base/memory/weak_ptr.h"
|
| #include "base/strings/string16.h"
|
| +#include "content/renderer/media/webcontentdecryptionmoduleresult_helper.h"
|
| #include "third_party/WebKit/public/platform/WebContentDecryptionModule.h"
|
|
|
| namespace blink {
|
| @@ -64,12 +66,25 @@ class WebContentDecryptionModuleImpl
|
| virtual blink::WebContentDecryptionModuleSession* createSession(
|
| blink::WebContentDecryptionModuleSession::Client* client);
|
|
|
| + virtual void setServerCertificate(
|
| + const uint8* server_certificate,
|
| + size_t server_certificate_length,
|
| + blink::WebContentDecryptionModuleResult result);
|
| +
|
| private:
|
| // Takes reference to |adapter|.
|
| WebContentDecryptionModuleImpl(scoped_refptr<CdmSessionAdapter> adapter);
|
|
|
| scoped_refptr<CdmSessionAdapter> adapter_;
|
|
|
| + // Keep track of all the outstanding WebContentDecryptionModuleResult objects.
|
| + WebContentDecryptionModuleResultHelper outstanding_results_;
|
| +
|
| + // Since promises will live until they are fired, use a weak reference when
|
| + // creating a promise in case this class disappears before the promise
|
| + // actually fires.
|
| + base::WeakPtrFactory<WebContentDecryptionModuleImpl> weak_ptr_factory_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(WebContentDecryptionModuleImpl);
|
| };
|
|
|
|
|