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

Side by Side Diff: extensions/browser/updater/extension_downloader.cc

Issue 2133083002: Remove all remaining traces of MessageLoopProxy. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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 (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 "extensions/browser/updater/extension_downloader.h" 5 #include "extensions/browser/updater/extension_downloader.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after
741 bool is_secure = fetch->url.SchemeIsCryptographic(); 741 bool is_secure = fetch->url.SchemeIsCryptographic();
742 if (fetch->credentials != ExtensionFetch::CREDENTIALS_COOKIES || !is_secure) { 742 if (fetch->credentials != ExtensionFetch::CREDENTIALS_COOKIES || !is_secure) {
743 load_flags |= net::LOAD_DO_NOT_SEND_COOKIES | net::LOAD_DO_NOT_SAVE_COOKIES; 743 load_flags |= net::LOAD_DO_NOT_SEND_COOKIES | net::LOAD_DO_NOT_SAVE_COOKIES;
744 } 744 }
745 extension_fetcher_->SetLoadFlags(load_flags); 745 extension_fetcher_->SetLoadFlags(load_flags);
746 746
747 // Download CRX files to a temp file. The blacklist is small and will be 747 // Download CRX files to a temp file. The blacklist is small and will be
748 // processed in memory, so it is fetched into a string. 748 // processed in memory, so it is fetched into a string.
749 if (fetch->id != kBlacklistAppID) { 749 if (fetch->id != kBlacklistAppID) {
750 extension_fetcher_->SaveResponseToTemporaryFile( 750 extension_fetcher_->SaveResponseToTemporaryFile(
751 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::FILE)); 751 BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE));
752 } 752 }
753 753
754 if (fetch->credentials == ExtensionFetch::CREDENTIALS_OAUTH2_TOKEN && 754 if (fetch->credentials == ExtensionFetch::CREDENTIALS_OAUTH2_TOKEN &&
755 is_secure) { 755 is_secure) {
756 if (access_token_.empty()) { 756 if (access_token_.empty()) {
757 // We should try OAuth2, but we have no token cached. This 757 // We should try OAuth2, but we have no token cached. This
758 // ExtensionFetcher will be started once the token fetch is complete, 758 // ExtensionFetcher will be started once the token fetch is complete,
759 // in either OnTokenFetchSuccess or OnTokenFetchFailure. 759 // in either OnTokenFetchSuccess or OnTokenFetchFailure.
760 DCHECK(identity_provider_.get()); 760 DCHECK(identity_provider_.get());
761 OAuth2TokenService::ScopeSet webstore_scopes; 761 OAuth2TokenService::ScopeSet webstore_scopes;
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
940 const GURL& update_url, 940 const GURL& update_url,
941 int request_id) { 941 int request_id) {
942 ManifestFetchData::PingMode ping_mode = ManifestFetchData::NO_PING; 942 ManifestFetchData::PingMode ping_mode = ManifestFetchData::NO_PING;
943 if (update_url.DomainIs(ping_enabled_domain_.c_str())) 943 if (update_url.DomainIs(ping_enabled_domain_.c_str()))
944 ping_mode = ManifestFetchData::PING_WITH_ENABLED_STATE; 944 ping_mode = ManifestFetchData::PING_WITH_ENABLED_STATE;
945 return new ManifestFetchData( 945 return new ManifestFetchData(
946 update_url, request_id, brand_code_, manifest_query_params_, ping_mode); 946 update_url, request_id, brand_code_, manifest_query_params_, ping_mode);
947 } 947 }
948 948
949 } // namespace extensions 949 } // namespace extensions
OLDNEW
« no previous file with comments | « extensions/browser/sandboxed_unpacker.cc ('k') | extensions/browser/updater/safe_manifest_parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698