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

Side by Side Diff: chrome/browser/extensions/webstore_standalone_installer.cc

Issue 13949011: Cleanup: Remove unnecessary ".get()" from scoped_ptrs<>. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/extensions/webstore_installer.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/extensions/webstore_standalone_installer.h" 5 #include "chrome/browser/extensions/webstore_standalone_installer.h"
6 6
7 #include "base/values.h" 7 #include "base/values.h"
8 #include "chrome/browser/extensions/crx_installer.h" 8 #include "chrome/browser/extensions/crx_installer.h"
9 #include "chrome/browser/extensions/extension_install_prompt.h" 9 #include "chrome/browser/extensions/extension_install_prompt.h"
10 #include "chrome/browser/extensions/extension_install_ui.h" 10 #include "chrome/browser/extensions/extension_install_ui.h"
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 const std::string& id, 226 const std::string& id,
227 const std::string& error, 227 const std::string& error,
228 WebstoreInstaller::FailureReason cancelled) { 228 WebstoreInstaller::FailureReason cancelled) {
229 CHECK_EQ(id_, id); 229 CHECK_EQ(id_, id);
230 CompleteInstall(error); 230 CompleteInstall(error);
231 } 231 }
232 232
233 void WebstoreStandaloneInstaller::AbortInstall() { 233 void WebstoreStandaloneInstaller::AbortInstall() {
234 callback_.Reset(); 234 callback_.Reset();
235 // Abort any in-progress fetches. 235 // Abort any in-progress fetches.
236 if (webstore_data_fetcher_.get()) { 236 if (webstore_data_fetcher_) {
237 webstore_data_fetcher_.reset(); 237 webstore_data_fetcher_.reset();
238 Release(); // Matches the AddRef in BeginInstall. 238 Release(); // Matches the AddRef in BeginInstall.
239 } 239 }
240 } 240 }
241 241
242 void WebstoreStandaloneInstaller::CompleteInstall(const std::string& error) { 242 void WebstoreStandaloneInstaller::CompleteInstall(const std::string& error) {
243 // Clear webstore_data_fetcher_ so that WebContentsDestroyed will no longer 243 // Clear webstore_data_fetcher_ so that WebContentsDestroyed will no longer
244 // call Release in case the WebContents is destroyed before this object. 244 // call Release in case the WebContents is destroyed before this object.
245 scoped_ptr<WebstoreDataFetcher> webstore_data_fetcher( 245 scoped_ptr<WebstoreDataFetcher> webstore_data_fetcher(
246 webstore_data_fetcher_.Pass()); 246 webstore_data_fetcher_.Pass());
(...skipping 20 matching lines...) Expand all
267 } 267 }
268 268
269 install_ui_.reset(new ExtensionInstallPrompt(GetWebContents())); 269 install_ui_.reset(new ExtensionInstallPrompt(GetWebContents()));
270 install_ui_->ConfirmStandaloneInstall(this, 270 install_ui_->ConfirmStandaloneInstall(this,
271 localized_extension_for_display_, 271 localized_extension_for_display_,
272 &icon_, 272 &icon_,
273 *install_prompt_); 273 *install_prompt_);
274 } 274 }
275 275
276 } // namespace extensions 276 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/webstore_installer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698