Roll src/third_party/WebKit d9c6159:8139f33 (svn 201974:201975)
[chromium-blink-merge.git] / extensions / browser / api / networking_private / networking_private_event_router.h
blob14ba74ee319322506e6c4a863da2ed94bb2c6b34
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
3 // found in the LICENSE file.
5 #ifndef EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_EVENT_ROUTER_H_
6 #define EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_EVENT_ROUTER_H_
8 #include "components/keyed_service/core/keyed_service.h"
9 #include "extensions/browser/event_router.h"
11 namespace content {
12 class BrowserContext;
15 namespace extensions {
17 class NetworkingPrivateDelegate;
19 // This is an event router that will observe listeners to |NetworksChanged| and
20 // |NetworkListChanged| events. On ChromeOS it will forward these events
21 // from the NetworkStateHandler to the JavaScript Networking API.
22 class NetworkingPrivateEventRouter : public KeyedService,
23 public EventRouter::Observer {
24 public:
25 static NetworkingPrivateEventRouter* Create(
26 content::BrowserContext* browser_context);
28 protected:
29 NetworkingPrivateEventRouter() {}
31 private:
32 DISALLOW_COPY_AND_ASSIGN(NetworkingPrivateEventRouter);
35 } // namespace extensions
37 #endif // EXTENSIONS_BROWSER_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_EVENT_ROUTER_H_