OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/web_resource/web_resource_service.h" | 5 #include "chrome/browser/web_resource/web_resource_service.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/file_path.h" | 8 #include "base/file_path.h" |
9 #include "base/string_util.h" | 9 #include "base/string_util.h" |
10 #include "base/string_number_conversions.h" | 10 #include "base/string_number_conversions.h" |
(...skipping 500 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
511 for (ExtensionList::const_iterator iter = extensions->begin(); | 511 for (ExtensionList::const_iterator iter = extensions->begin(); |
512 iter != extensions->end(); | 512 iter != extensions->end(); |
513 ++iter) { | 513 ++iter) { |
514 if ((*iter)->location() == Extension::INTERNAL) { | 514 if ((*iter)->location() == Extension::INTERNAL) { |
515 has_extensions = true; | 515 has_extensions = true; |
516 break; | 516 break; |
517 } | 517 } |
518 } | 518 } |
519 } | 519 } |
520 | 520 |
| 521 // Note that HasProfileSyncService() will be false for ChromeOS, so |
| 522 // promo_options will only be true if the user has an extension installed. |
| 523 // See http://crosbug/10209 |
521 bool promo_options = | 524 bool promo_options = |
522 sync_ui_util::GetStatus( | 525 (profile->HasProfileSyncService() && |
523 profile->GetProfileSyncService()) == sync_ui_util::SYNCED || | 526 sync_ui_util::GetStatus( |
524 has_extensions; | 527 profile->GetProfileSyncService()) == sync_ui_util::SYNCED) || |
| 528 has_extensions; |
525 | 529 |
526 return !promo_closed && | 530 return !promo_closed && |
527 promo_options && | 531 promo_options && |
528 g_browser_process->GetApplicationLocale() == "en-US"; | 532 g_browser_process->GetApplicationLocale() == "en-US"; |
529 } | 533 } |
530 | 534 |
531 } // namespace WebResourceService | 535 } // namespace WebResourceService |
532 | 536 |
OLD | NEW |