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

Side by Side Diff: chrome/browser/ui/app_list/search/webstore/webstore_result.cc

Issue 1865213004: Convert //chrome/browser/ui 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/app_list/search/webstore/webstore_result.h" 5 #include "chrome/browser/ui/app_list/search/webstore/webstore_result.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 if (is_paid_) { 89 if (is_paid_) {
90 // Paid apps cannot be installed directly from the launcher. Instead, open 90 // Paid apps cannot be installed directly from the launcher. Instead, open
91 // the webstore page for the app. 91 // the webstore page for the app.
92 Open(event_flags); 92 Open(event_flags);
93 return; 93 return;
94 } 94 }
95 95
96 StartInstall(); 96 StartInstall();
97 } 97 }
98 98
99 scoped_ptr<SearchResult> WebstoreResult::Duplicate() const { 99 std::unique_ptr<SearchResult> WebstoreResult::Duplicate() const {
100 scoped_ptr<SearchResult> copy(new WebstoreResult( 100 std::unique_ptr<SearchResult> copy(new WebstoreResult(
101 profile_, app_id_, icon_url_, is_paid_, item_type_, controller_)); 101 profile_, app_id_, icon_url_, is_paid_, item_type_, controller_));
102 copy->set_title(title()); 102 copy->set_title(title());
103 copy->set_title_tags(title_tags()); 103 copy->set_title_tags(title_tags());
104 copy->set_relevance(relevance()); 104 copy->set_relevance(relevance());
105 return copy; 105 return copy;
106 } 106 }
107 107
108 void WebstoreResult::InitAndStartObserving() { 108 void WebstoreResult::InitAndStartObserving() {
109 DCHECK(!install_tracker_ && !extension_registry_); 109 DCHECK(!install_tracker_ && !extension_registry_);
110 110
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 238
239 void WebstoreResult::OnShutdown() { 239 void WebstoreResult::OnShutdown() {
240 StopObservingInstall(); 240 StopObservingInstall();
241 } 241 }
242 242
243 void WebstoreResult::OnShutdown(extensions::ExtensionRegistry* registry) { 243 void WebstoreResult::OnShutdown(extensions::ExtensionRegistry* registry) {
244 StopObservingRegistry(); 244 StopObservingRegistry();
245 } 245 }
246 246
247 } // namespace app_list 247 } // namespace app_list
OLDNEW
« no previous file with comments | « chrome/browser/ui/app_list/search/webstore/webstore_result.h ('k') | chrome/browser/ui/app_list/speech_auth_helper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698