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

Side by Side Diff: chrome/common/extensions/chrome_extensions_client.cc

Issue 1220963005: Update base::StartsWith calls to new form (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@starts_with
Patch Set: Created 5 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 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/common/extensions/chrome_extensions_client.h" 5 #include "chrome/common/extensions/chrome_extensions_client.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/metrics/histogram_macros.h" 9 #include "base/metrics/histogram_macros.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 349 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 return extension_urls::GetDefaultWebstoreUpdateUrl().spec(); 360 return extension_urls::GetDefaultWebstoreUpdateUrl().spec();
361 } 361 }
362 362
363 bool ChromeExtensionsClient::IsBlacklistUpdateURL(const GURL& url) const { 363 bool ChromeExtensionsClient::IsBlacklistUpdateURL(const GURL& url) const {
364 // The extension blacklist URL is returned from the update service and 364 // The extension blacklist URL is returned from the update service and
365 // therefore not determined by Chromium. If the location of the blacklist file 365 // therefore not determined by Chromium. If the location of the blacklist file
366 // ever changes, we need to update this function. A DCHECK in the 366 // ever changes, we need to update this function. A DCHECK in the
367 // ExtensionUpdater ensures that we notice a change. This is the full URL 367 // ExtensionUpdater ensures that we notice a change. This is the full URL
368 // of a blacklist: 368 // of a blacklist:
369 // http://www.gstatic.com/chrome/extensions/blacklist/l_0_0_0_7.txt 369 // http://www.gstatic.com/chrome/extensions/blacklist/l_0_0_0_7.txt
370 return base::StartsWithASCII(url.spec(), kExtensionBlocklistUrlPrefix, 370 return base::StartsWith(url.spec(), kExtensionBlocklistUrlPrefix,
371 true) || 371 base::CompareCase::SENSITIVE) ||
372 base::StartsWithASCII(url.spec(), kExtensionBlocklistHttpsUrlPrefix, 372 base::StartsWith(url.spec(), kExtensionBlocklistHttpsUrlPrefix,
373 true); 373 base::CompareCase::SENSITIVE);
374 } 374 }
375 375
376 std::set<base::FilePath> ChromeExtensionsClient::GetBrowserImagePaths( 376 std::set<base::FilePath> ChromeExtensionsClient::GetBrowserImagePaths(
377 const Extension* extension) { 377 const Extension* extension) {
378 std::set<base::FilePath> image_paths = 378 std::set<base::FilePath> image_paths =
379 ExtensionsClient::GetBrowserImagePaths(extension); 379 ExtensionsClient::GetBrowserImagePaths(extension);
380 380
381 // Theme images 381 // Theme images
382 const base::DictionaryValue* theme_images = 382 const base::DictionaryValue* theme_images =
383 extensions::ThemeInfo::GetImages(extension); 383 extensions::ThemeInfo::GetImages(extension);
(...skipping 18 matching lines...) Expand all
402 402
403 return image_paths; 403 return image_paths;
404 } 404 }
405 405
406 // static 406 // static
407 ChromeExtensionsClient* ChromeExtensionsClient::GetInstance() { 407 ChromeExtensionsClient* ChromeExtensionsClient::GetInstance() {
408 return g_client.Pointer(); 408 return g_client.Pointer();
409 } 409 }
410 410
411 } // namespace extensions 411 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698