Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef EXTENSIONS_BROWSER_EVENT_ROUTER_H_ | 5 #ifndef EXTENSIONS_BROWSER_EVENT_ROUTER_H_ |
| 6 #define EXTENSIONS_BROWSER_EVENT_ROUTER_H_ | 6 #define EXTENSIONS_BROWSER_EVENT_ROUTER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 315 EventRouter::UserGestureState user_gesture; | 315 EventRouter::UserGestureState user_gesture; |
| 316 | 316 |
| 317 // Extra information used to filter which events are sent to the listener. | 317 // Extra information used to filter which events are sent to the listener. |
| 318 EventFilteringInfo filter_info; | 318 EventFilteringInfo filter_info; |
| 319 | 319 |
| 320 // If specified, this is called before dispatching an event to each | 320 // If specified, this is called before dispatching an event to each |
| 321 // extension. The third argument is a mutable reference to event_args, | 321 // extension. The third argument is a mutable reference to event_args, |
| 322 // allowing the caller to provide different arguments depending on the | 322 // allowing the caller to provide different arguments depending on the |
| 323 // extension and profile. This is guaranteed to be called synchronously with | 323 // extension and profile. This is guaranteed to be called synchronously with |
| 324 // DispatchEvent, so callers don't need to worry about lifetime. | 324 // DispatchEvent, so callers don't need to worry about lifetime. |
| 325 // | |
| 326 // NOTE: the Extension argument to this may be NULL if it's possible for this | |
|
Charlie Reis
2014/07/22 21:10:24
nit: if -> because
not at google - send to devlin
2014/07/22 23:42:32
Done.
| |
| 327 // event to be dispatched to non-extension processes, like WebUI. | |
| 325 WillDispatchCallback will_dispatch_callback; | 328 WillDispatchCallback will_dispatch_callback; |
| 326 | 329 |
| 327 // If true, this event will always be dispatched to ephemeral apps, regardless | 330 // If true, this event will always be dispatched to ephemeral apps, regardless |
| 328 // of whether they are running or inactive. Defaults to false. | 331 // of whether they are running or inactive. Defaults to false. |
| 329 // Most events can only be dispatched to ephemeral apps that are already | 332 // Most events can only be dispatched to ephemeral apps that are already |
| 330 // running. Cached ephemeral apps are inactive until launched by the user. | 333 // running. Cached ephemeral apps are inactive until launched by the user. |
| 331 bool can_load_ephemeral_apps; | 334 bool can_load_ephemeral_apps; |
| 332 | 335 |
| 333 Event(const std::string& event_name, | 336 Event(const std::string& event_name, |
| 334 scoped_ptr<base::ListValue> event_args); | 337 scoped_ptr<base::ListValue> event_args); |
| (...skipping 24 matching lines...) Expand all Loading... | |
| 359 // "webRequest.onCompleted/123". | 362 // "webRequest.onCompleted/123". |
| 360 const std::string event_name; | 363 const std::string event_name; |
| 361 | 364 |
| 362 const std::string extension_id; | 365 const std::string extension_id; |
| 363 content::BrowserContext* browser_context; | 366 content::BrowserContext* browser_context; |
| 364 }; | 367 }; |
| 365 | 368 |
| 366 } // namespace extensions | 369 } // namespace extensions |
| 367 | 370 |
| 368 #endif // EXTENSIONS_BROWSER_EVENT_ROUTER_H_ | 371 #endif // EXTENSIONS_BROWSER_EVENT_ROUTER_H_ |
| OLD | NEW |