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

Unified Diff: components/dom_distiller/core/distilled_content_store.h

Issue 1879613003: Convert //components/dom_distiller from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase 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
Index: components/dom_distiller/core/distilled_content_store.h
diff --git a/components/dom_distiller/core/distilled_content_store.h b/components/dom_distiller/core/distilled_content_store.h
index 3b17c2d368987f6bd47fba1e4ff68d03160880a2..bbee232ad1d81cecf4c60584d5dba18f7ba0c048 100644
--- a/components/dom_distiller/core/distilled_content_store.h
+++ b/components/dom_distiller/core/distilled_content_store.h
@@ -5,13 +5,13 @@
#ifndef COMPONENTS_DOM_DISTILLER_CORE_DOM_DISTILLER_CONTENT_STORE_H_
#define COMPONENTS_DOM_DISTILLER_CORE_DOM_DISTILLER_CONTENT_STORE_H_
+#include <memory>
#include <string>
#include "base/bind.h"
#include "base/containers/hash_tables.h"
#include "base/containers/mru_cache.h"
#include "base/macros.h"
-#include "base/memory/scoped_ptr.h"
#include "components/dom_distiller/core/article_entry.h"
#include "components/dom_distiller/core/proto/distilled_article.pb.h"
@@ -24,8 +24,9 @@ const int kDefaultMaxNumCachedEntries = 32;
// ArticleEntry.
class DistilledContentStore {
public:
- typedef base::Callback<
- void(bool /* success */, scoped_ptr<DistilledArticleProto>)> LoadCallback;
+ typedef base::Callback<void(bool /* success */,
+ std::unique_ptr<DistilledArticleProto>)>
+ LoadCallback;
typedef base::Callback<void(bool /* success */)> SaveCallback;
virtual void SaveContent(const ArticleEntry& entry,
@@ -77,7 +78,7 @@ class InMemoryContentStore : public DistilledContentStore {
void EraseUrlToIdMapping(const DistilledArticleProto& proto);
typedef base::MRUCache<std::string,
- scoped_ptr<DistilledArticleProto, CacheDeletor>>
+ std::unique_ptr<DistilledArticleProto, CacheDeletor>>
ContentMap;
typedef base::hash_map<std::string, std::string> UrlMap;

Powered by Google App Engine
This is Rietveld 408576698