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

Unified Diff: media/base/media_keys.h

Issue 1906423005: Replace scoped_ptr with std::unique_ptr in //media/base. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptr-media-base: android Created 4 years, 8 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 | « media/base/media_file_checker.cc ('k') | media/base/media_log.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/media_keys.h
diff --git a/media/base/media_keys.h b/media/base/media_keys.h
index 13c210c786a97913b580bcead9f5a9016c123ef1..d5fa98da09d40b9e165d1a64d667e3a1b6b17631 100644
--- a/media/base/media_keys.h
+++ b/media/base/media_keys.h
@@ -7,13 +7,13 @@
#include <stdint.h>
+#include <memory>
#include <string>
#include <vector>
#include "base/callback.h"
#include "base/macros.h"
#include "base/memory/ref_counted.h"
-#include "base/memory/scoped_ptr.h"
#include "base/memory/scoped_vector.h"
#include "media/base/eme_constants.h"
#include "media/base/media_export.h"
@@ -102,8 +102,9 @@ class MEDIA_EXPORT MediaKeys
// Provides a server certificate to be used to encrypt messages to the
// license server.
- virtual void SetServerCertificate(const std::vector<uint8_t>& certificate,
- scoped_ptr<SimpleCdmPromise> promise) = 0;
+ virtual void SetServerCertificate(
+ const std::vector<uint8_t>& certificate,
+ std::unique_ptr<SimpleCdmPromise> promise) = 0;
// Creates a session with |session_type|. Then generates a request with the
// |init_data_type| and |init_data|.
@@ -118,31 +119,31 @@ class MEDIA_EXPORT MediaKeys
SessionType session_type,
EmeInitDataType init_data_type,
const std::vector<uint8_t>& init_data,
- scoped_ptr<NewSessionCdmPromise> promise) = 0;
+ std::unique_ptr<NewSessionCdmPromise> promise) = 0;
// Loads a session with the |session_id| provided.
// Note: UpdateSession(), CloseSession() and RemoveSession() should only be
// called after the |promise| is resolved.
virtual void LoadSession(SessionType session_type,
const std::string& session_id,
- scoped_ptr<NewSessionCdmPromise> promise) = 0;
+ std::unique_ptr<NewSessionCdmPromise> promise) = 0;
// Updates a session specified by |session_id| with |response|.
virtual void UpdateSession(const std::string& session_id,
const std::vector<uint8_t>& response,
- scoped_ptr<SimpleCdmPromise> promise) = 0;
+ std::unique_ptr<SimpleCdmPromise> promise) = 0;
// Closes the session specified by |session_id|. The CDM should resolve or
// reject the |promise| when the call has been processed. This may be before
// the session is closed. Once the session is closed, a SessionClosedCB must
// also be called.
virtual void CloseSession(const std::string& session_id,
- scoped_ptr<SimpleCdmPromise> promise) = 0;
+ std::unique_ptr<SimpleCdmPromise> promise) = 0;
// Removes stored session data associated with the session specified by
// |session_id|.
virtual void RemoveSession(const std::string& session_id,
- scoped_ptr<SimpleCdmPromise> promise) = 0;
+ std::unique_ptr<SimpleCdmPromise> promise) = 0;
// Returns the CdmContext associated with |this|. The returned CdmContext is
// owned by |this| and the caller needs to make sure it is not used after
« no previous file with comments | « media/base/media_file_checker.cc ('k') | media/base/media_log.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698