| 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/ui/webui/extensions/extension_basic_info.h" | 5 #include "chrome/browser/ui/webui/extensions/extension_basic_info.h" |
| 6 | 6 |
| 7 #include "base/values.h" | 7 #include "base/values.h" |
| 8 #include "chrome/common/extensions/manifest_url_handler.h" | 8 #include "chrome/common/extensions/manifest_url_handler.h" |
| 9 #include "extensions/common/extension.h" | 9 #include "extensions/common/extension.h" |
| 10 #include "extensions/common/manifest_handlers/kiosk_mode_info.h" | 10 #include "extensions/common/manifest_handlers/kiosk_mode_info.h" |
| 11 #include "extensions/common/manifest_handlers/offline_enabled_info.h" | 11 #include "extensions/common/manifest_handlers/offline_enabled_info.h" |
| 12 #include "extensions/common/manifest_handlers/options_page_info.h" |
| 12 | 13 |
| 13 namespace { | 14 namespace { |
| 14 | 15 |
| 15 // Keys in the dictionary returned by GetExtensionBasicInfo(). | 16 // Keys in the dictionary returned by GetExtensionBasicInfo(). |
| 16 const char kDescriptionKey[] = "description"; | 17 const char kDescriptionKey[] = "description"; |
| 17 const char kEnabledKey[] = "enabled"; | 18 const char kEnabledKey[] = "enabled"; |
| 18 const char kHomepageUrlKey[] = "homepageUrl"; | 19 const char kHomepageUrlKey[] = "homepageUrl"; |
| 19 const char kIdKey[] = "id"; | 20 const char kIdKey[] = "id"; |
| 20 const char kNameKey[] = "name"; | 21 const char kNameKey[] = "name"; |
| 21 const char kKioskEnabledKey[] = "kioskEnabled"; | 22 const char kKioskEnabledKey[] = "kioskEnabled"; |
| (...skipping 17 matching lines...) Expand all Loading... |
| 39 info->SetBoolean(kKioskEnabledKey, | 40 info->SetBoolean(kKioskEnabledKey, |
| 40 KioskModeInfo::IsKioskEnabled(extension)); | 41 KioskModeInfo::IsKioskEnabled(extension)); |
| 41 info->SetBoolean(kKioskOnlyKey, | 42 info->SetBoolean(kKioskOnlyKey, |
| 42 KioskModeInfo::IsKioskOnly(extension)); | 43 KioskModeInfo::IsKioskOnly(extension)); |
| 43 info->SetBoolean(kOfflineEnabledKey, | 44 info->SetBoolean(kOfflineEnabledKey, |
| 44 OfflineEnabledInfo::IsOfflineEnabled(extension)); | 45 OfflineEnabledInfo::IsOfflineEnabled(extension)); |
| 45 info->SetString(kVersionKey, extension->VersionString()); | 46 info->SetString(kVersionKey, extension->VersionString()); |
| 46 info->SetString(kDescriptionKey, extension->description()); | 47 info->SetString(kDescriptionKey, extension->description()); |
| 47 info->SetString( | 48 info->SetString( |
| 48 kOptionsUrlKey, | 49 kOptionsUrlKey, |
| 49 ManifestURL::GetOptionsPage(extension).possibly_invalid_spec()); | 50 OptionsPageInfo::GetOptionsPage(extension).possibly_invalid_spec()); |
| 50 info->SetString( | 51 info->SetString( |
| 51 kHomepageUrlKey, | 52 kHomepageUrlKey, |
| 52 ManifestURL::GetHomepageURL(extension).possibly_invalid_spec()); | 53 ManifestURL::GetHomepageURL(extension).possibly_invalid_spec()); |
| 53 info->SetString( | 54 info->SetString( |
| 54 kDetailsUrlKey, | 55 kDetailsUrlKey, |
| 55 ManifestURL::GetDetailsURL(extension).possibly_invalid_spec()); | 56 ManifestURL::GetDetailsURL(extension).possibly_invalid_spec()); |
| 56 info->SetBoolean(kPackagedAppKey, extension->is_platform_app()); | 57 info->SetBoolean(kPackagedAppKey, extension->is_platform_app()); |
| 57 } | 58 } |
| 58 | 59 |
| 59 } // namespace extensions | 60 } // namespace extensions |
| OLD | NEW |