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

Unified Diff: chrome/browser/extensions/webstore_standalone_installer.cc

Issue 1871713002: Convert //chrome/browser/extensions from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and fix header 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: chrome/browser/extensions/webstore_standalone_installer.cc
diff --git a/chrome/browser/extensions/webstore_standalone_installer.cc b/chrome/browser/extensions/webstore_standalone_installer.cc
index da7483dfe651d343e166e74b52e8532e518cdde0..33c164f8d7afa833e2f7f4ff5d87ae4e4daff1f5 100644
--- a/chrome/browser/extensions/webstore_standalone_installer.cc
+++ b/chrome/browser/extensions/webstore_standalone_installer.cc
@@ -6,6 +6,7 @@
#include <utility>
+#include "base/memory/ptr_util.h"
#include "base/values.h"
#include "base/version.h"
#include "chrome/browser/extensions/crx_installer.h"
@@ -170,18 +171,17 @@ void WebstoreStandaloneInstaller::OnManifestParsed() {
ProceedWithInstallPrompt();
}
-scoped_ptr<ExtensionInstallPrompt>
+std::unique_ptr<ExtensionInstallPrompt>
WebstoreStandaloneInstaller::CreateInstallUI() {
- return make_scoped_ptr(new ExtensionInstallPrompt(GetWebContents()));
+ return base::WrapUnique(new ExtensionInstallPrompt(GetWebContents()));
}
-scoped_ptr<WebstoreInstaller::Approval>
+std::unique_ptr<WebstoreInstaller::Approval>
WebstoreStandaloneInstaller::CreateApproval() const {
- scoped_ptr<WebstoreInstaller::Approval> approval(
+ std::unique_ptr<WebstoreInstaller::Approval> approval(
WebstoreInstaller::Approval::CreateWithNoInstallPrompt(
- profile_,
- id_,
- scoped_ptr<base::DictionaryValue>(manifest_.get()->DeepCopy()),
+ profile_, id_,
+ std::unique_ptr<base::DictionaryValue>(manifest_.get()->DeepCopy()),
true));
approval->skip_post_install_ui = !ShouldShowPostInstallUI();
approval->use_app_installed_bubble = ShouldShowAppInstalledBubble();
@@ -204,7 +204,7 @@ void WebstoreStandaloneInstaller::OnInstallPromptDone(
DCHECK(result == ExtensionInstallPrompt::Result::ACCEPTED);
- scoped_ptr<WebstoreInstaller::Approval> approval = CreateApproval();
+ std::unique_ptr<WebstoreInstaller::Approval> approval = CreateApproval();
ExtensionService* extension_service =
ExtensionSystem::Get(profile_)->extension_service();
@@ -244,7 +244,7 @@ void WebstoreStandaloneInstaller::OnWebstoreRequestFailure() {
}
void WebstoreStandaloneInstaller::OnWebstoreResponseParseSuccess(
- scoped_ptr<base::DictionaryValue> webstore_data) {
+ std::unique_ptr<base::DictionaryValue> webstore_data) {
OnWebStoreDataFetcherDone();
if (!CheckRequestorAlive()) {
« no previous file with comments | « chrome/browser/extensions/webstore_standalone_installer.h ('k') | chrome/browser/extensions/webstore_startup_installer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698