Index: chrome/browser/notifications/desktop_notification_service.h |
diff --git a/chrome/browser/notifications/desktop_notification_service.h b/chrome/browser/notifications/desktop_notification_service.h |
index ca71f572935e3bb6841c20a7dfbecbd2626cf105..7d99829591bdd2dddd3ba6cb4dfe0fab496260ee 100644 |
--- a/chrome/browser/notifications/desktop_notification_service.h |
+++ b/chrome/browser/notifications/desktop_notification_service.h |
@@ -22,7 +22,9 @@ |
#include "chrome/browser/notifications/extension_welcome_notification.h" |
#include "components/content_settings/core/common/content_settings.h" |
#include "components/keyed_service/core/keyed_service.h" |
+#if defined(ENABLE_EXTENSIONS) |
Jun Mukai
2014/09/22 07:22:47
Please move this below. Our style is:
#include ..
|
#include "extensions/browser/extension_registry_observer.h" |
+#endif |
#include "third_party/WebKit/public/platform/WebNotificationPermission.h" |
#include "third_party/WebKit/public/web/WebTextDirection.h" |
#include "ui/message_center/notifier_settings.h" |
@@ -40,9 +42,11 @@ class RenderFrameHost; |
struct ShowDesktopNotificationHostMsgParams; |
} |
+#if defined(ENABLE_EXTENSIONS) |
namespace extensions { |
class ExtensionRegistry; |
} |
+#endif |
namespace gfx { |
class Image; |
@@ -58,9 +62,12 @@ typedef base::Callback<void(blink::WebNotificationPermission)> |
// The DesktopNotificationService is an object, owned by the Profile, |
// which provides the creation of desktop "toasts" to web pages and workers. |
-class DesktopNotificationService |
- : public PermissionContextBase, |
- public extensions::ExtensionRegistryObserver { |
+class DesktopNotificationService : public PermissionContextBase |
+#if defined(ENABLE_EXTENSIONS) |
+ , |
+ public extensions::ExtensionRegistryObserver |
+#endif |
+ { |
public: |
// Register profile-specific prefs of notifications. |
static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* prefs); |
@@ -130,11 +137,13 @@ class DesktopNotificationService |
const message_center::NotifierId& notifier_id, |
bool enabled); |
+#if defined(ENABLE_EXTENSIONS) |
// extensions::ExtensionRegistryObserver: |
virtual void OnExtensionUninstalled( |
content::BrowserContext* browser_context, |
const extensions::Extension* extension, |
extensions::UninstallReason reason) OVERRIDE; |
+#endif |
// The profile which owns this object. |
Profile* profile_; |
@@ -151,10 +160,12 @@ class DesktopNotificationService |
// On-memory data for the availability of system_component. |
std::set<std::string> disabled_system_component_ids_; |
+#if defined(ENABLE_EXTENSIONS) |
// An observer to listen when extension is uninstalled. |
ScopedObserver<extensions::ExtensionRegistry, |
extensions::ExtensionRegistryObserver> |
extension_registry_observer_; |
+#endif |
// Welcome Notification |
scoped_ptr<ExtensionWelcomeNotification> chrome_now_welcome_notification_; |