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

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

Issue 17524010: Change default Omaha installsource param from "" to "ondemand" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 | « no previous file | 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_installer.h" 5 #include "chrome/browser/extensions/webstore_installer.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/file_util.h" 10 #include "base/file_util.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 const char kApprovalKey[] = "extensions.webstore_installer"; 59 const char kApprovalKey[] = "extensions.webstore_installer";
60 60
61 const char kInvalidIdError[] = "Invalid id"; 61 const char kInvalidIdError[] = "Invalid id";
62 const char kNoBrowserError[] = "No browser found"; 62 const char kNoBrowserError[] = "No browser found";
63 const char kDownloadDirectoryError[] = "Could not create download directory"; 63 const char kDownloadDirectoryError[] = "Could not create download directory";
64 const char kDownloadCanceledError[] = "Download canceled"; 64 const char kDownloadCanceledError[] = "Download canceled";
65 const char kInstallCanceledError[] = "Install canceled"; 65 const char kInstallCanceledError[] = "Install canceled";
66 const char kDownloadInterruptedError[] = "Download interrupted"; 66 const char kDownloadInterruptedError[] = "Download interrupted";
67 const char kInvalidDownloadError[] = "Download was not a CRX"; 67 const char kInvalidDownloadError[] = "Download was not a CRX";
68 const char kInlineInstallSource[] = "inline"; 68 const char kInlineInstallSource[] = "inline";
69 const char kDefaultInstallSource[] = ""; 69 const char kDefaultInstallSource[] = "ondemand";
70 70
71 base::FilePath* g_download_directory_for_tests = NULL; 71 base::FilePath* g_download_directory_for_tests = NULL;
72 72
73 // Must be executed on the FILE thread. 73 // Must be executed on the FILE thread.
74 void GetDownloadFilePath( 74 void GetDownloadFilePath(
75 const base::FilePath& download_directory, const std::string& id, 75 const base::FilePath& download_directory, const std::string& id,
76 const base::Callback<void(const base::FilePath&)>& callback) { 76 const base::Callback<void(const base::FilePath&)>& callback) {
77 base::FilePath directory(g_download_directory_for_tests ? 77 base::FilePath directory(g_download_directory_for_tests ?
78 *g_download_directory_for_tests : download_directory); 78 *g_download_directory_for_tests : download_directory);
79 79
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after
428 void WebstoreInstaller::ReportSuccess() { 428 void WebstoreInstaller::ReportSuccess() {
429 if (delegate_) { 429 if (delegate_) {
430 delegate_->OnExtensionInstallSuccess(id_); 430 delegate_->OnExtensionInstallSuccess(id_);
431 delegate_ = NULL; 431 delegate_ = NULL;
432 } 432 }
433 433
434 Release(); // Balanced in Start(). 434 Release(); // Balanced in Start().
435 } 435 }
436 436
437 } // namespace extensions 437 } // namespace extensions
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698