| OLD | NEW |
| 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/browser/extensions/extension_util.h" | 5 #include "chrome/browser/extensions/extension_util.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/metrics/field_trial.h" | 9 #include "base/metrics/field_trial.h" |
| 10 #include "base/values.h" | 10 #include "base/values.h" |
| (...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 338 dict->SetString("name", extension->name()); | 338 dict->SetString("name", extension->name()); |
| 339 | 339 |
| 340 GURL icon = extensions::ExtensionIconSource::GetIconURL( | 340 GURL icon = extensions::ExtensionIconSource::GetIconURL( |
| 341 extension, | 341 extension, |
| 342 extension_misc::EXTENSION_ICON_SMALLISH, | 342 extension_misc::EXTENSION_ICON_SMALLISH, |
| 343 ExtensionIconSet::MATCH_BIGGER, | 343 ExtensionIconSet::MATCH_BIGGER, |
| 344 false, // Not grayscale. | 344 false, // Not grayscale. |
| 345 NULL); // Don't set bool if exists. | 345 NULL); // Don't set bool if exists. |
| 346 dict->SetString("icon", icon.spec()); | 346 dict->SetString("icon", icon.spec()); |
| 347 | 347 |
| 348 return dict.Pass(); | 348 return dict; |
| 349 } | 349 } |
| 350 | 350 |
| 351 const gfx::ImageSkia& GetDefaultAppIcon() { | 351 const gfx::ImageSkia& GetDefaultAppIcon() { |
| 352 return *ResourceBundle::GetSharedInstance().GetImageSkiaNamed( | 352 return *ResourceBundle::GetSharedInstance().GetImageSkiaNamed( |
| 353 IDR_APP_DEFAULT_ICON); | 353 IDR_APP_DEFAULT_ICON); |
| 354 } | 354 } |
| 355 | 355 |
| 356 const gfx::ImageSkia& GetDefaultExtensionIcon() { | 356 const gfx::ImageSkia& GetDefaultExtensionIcon() { |
| 357 return *ResourceBundle::GetSharedInstance().GetImageSkiaNamed( | 357 return *ResourceBundle::GetSharedInstance().GetImageSkiaNamed( |
| 358 IDR_EXTENSION_DEFAULT_ICON); | 358 IDR_EXTENSION_DEFAULT_ICON); |
| (...skipping 24 matching lines...) Expand all Loading... |
| 383 base::FieldTrialList::FindFullName( | 383 base::FieldTrialList::FindFullName( |
| 384 kSupervisedUserExtensionPermissionIncreaseFieldTrialName); | 384 kSupervisedUserExtensionPermissionIncreaseFieldTrialName); |
| 385 std::string value = variations::GetVariationParamValue( | 385 std::string value = variations::GetVariationParamValue( |
| 386 kSupervisedUserExtensionPermissionIncreaseFieldTrialName, | 386 kSupervisedUserExtensionPermissionIncreaseFieldTrialName, |
| 387 profile->IsChild() ? "child_account" : "legacy_supervised_user"); | 387 profile->IsChild() ? "child_account" : "legacy_supervised_user"); |
| 388 return value == "true"; | 388 return value == "true"; |
| 389 } | 389 } |
| 390 | 390 |
| 391 } // namespace util | 391 } // namespace util |
| 392 } // namespace extensions | 392 } // namespace extensions |
| OLD | NEW |