Chromium Code Reviews| Index: chrome/common/extensions/manifest_url_info.cc |
| diff --git a/chrome/common/extensions/manifest_url_info.cc b/chrome/common/extensions/manifest_url_info.cc |
| index 956f7b57a76a8da9e0f62bb56eac314b7803e43a..fb6426e7da8285807775880399bccdb3b9ef486c 100644 |
| --- a/chrome/common/extensions/manifest_url_info.cc |
| +++ b/chrome/common/extensions/manifest_url_info.cc |
| @@ -14,10 +14,7 @@ namespace extensions { |
| const GURL& ManifestURLInfo::GetDevToolsPage(const Extension* extension) { |
| ManifestURLInfo* info = static_cast<ManifestURLInfo*>( |
| extension->GetManifestData(keys::kDevToolsPage)); |
| - |
| - if (info) |
| - return info->url_; |
| - return GURL::EmptyGURL(); |
| + return info ? info->url_ : GURL::EmptyGURL(); |
| } |
| // static |
| @@ -32,4 +29,18 @@ const GURL ManifestURLInfo::GetHomepageURL(const Extension* extension) { |
| GURL::EmptyGURL(); |
| } |
| +// static |
| +const GURL& ManifestURLInfo::GetUpdateURL(const Extension* extension) { |
|
Yoyo Zhou
2013/01/03 23:16:00
Since these 2 are very similar to GetDevToolsPage,
Joe Thomas
2013/01/04 01:36:27
Done.
|
| + ManifestURLInfo* info = static_cast<ManifestURLInfo*>( |
| + extension->GetManifestData(keys::kUpdateURL)); |
| + return info ? info->url_ : GURL::EmptyGURL(); |
| +} |
| + |
| +// static |
| +const GURL& ManifestURLInfo::GetOptionsPage(const Extension* extension) { |
| + ManifestURLInfo* info = static_cast<ManifestURLInfo*>( |
| + extension->GetManifestData(keys::kOptionsPage)); |
| + return info ? info->url_ : GURL::EmptyGURL(); |
| +} |
| + |
| } // namespace extensions |