Index: chrome/browser/background/background_application_list_model.cc |
diff --git a/chrome/browser/background/background_application_list_model.cc b/chrome/browser/background/background_application_list_model.cc |
index 39f604dbae9a7f69358ea334a3f31ef800dae9a0..7488bb3ef3ee016cedba7d3d67bf51b8b49138f6 100644 |
--- a/chrome/browser/background/background_application_list_model.cc |
+++ b/chrome/browser/background/background_application_list_model.cc |
@@ -280,29 +280,6 @@ int BackgroundApplicationListModel::GetPosition( |
} |
// static |
-bool BackgroundApplicationListModel::RequiresBackgroundModeForPushMessaging( |
- const Extension& extension) { |
- // No PushMessaging permission - does not require the background mode. |
- if (!extension.permissions_data()->HasAPIPermission( |
- APIPermission::kPushMessaging)) { |
- return false; |
- } |
- |
- // If in the whitelist, then does not require background mode even if |
- // uses push messaging. |
- // TODO(dimich): remove this whitelist once we have a better way to keep |
- // listening for GCM. http://crbug.com/311268 |
- std::string hexencoded_id_hash = |
- crx_file::id_util::HashedIdInHex(extension.id()); |
- // The id starting from "9A04..." is a one from unit test. |
- if (hexencoded_id_hash == "C41AD9DCD670210295614257EF8C9945AD68D86E" || |
- hexencoded_id_hash == "9A0417016F345C934A1A88F55CA17C05014EEEBA") |
- return false; |
- |
- return true; |
-} |
- |
-// static |
bool BackgroundApplicationListModel::IsBackgroundApp( |
const Extension& extension, Profile* profile) { |
// An extension is a "background app" if it has the "background API" |
@@ -316,12 +293,11 @@ bool BackgroundApplicationListModel::IsBackgroundApp( |
if (extensions::util::IsEphemeralApp(extension.id(), profile)) |
return false; |
- // Not a background app if we don't have the background permission or |
- // the push messaging permission |
+ // Not a background app if we don't have the background permission. |
if (!extension.permissions_data()->HasAPIPermission( |
- APIPermission::kBackground) && |
- !RequiresBackgroundModeForPushMessaging(extension)) |
+ APIPermission::kBackground)) { |
return false; |
+ } |
// Extensions and packaged apps with background permission are always treated |
// as background apps. |