OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #include "chrome/browser/extensions/api/automation_internal/automation_event_rou
ter.h" | 5 #include "chrome/browser/extensions/api/automation_internal/automation_event_rou
ter.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 | 10 |
11 #include "base/stl_util.h" | 11 #include "base/stl_util.h" |
12 #include "base/values.h" | 12 #include "base/values.h" |
13 #include "build/build_config.h" | 13 #include "build/build_config.h" |
14 #include "chrome/browser/profiles/profile_manager.h" | 14 #include "chrome/browser/profiles/profile_manager.h" |
15 #include "chrome/common/extensions/api/automation_internal.h" | 15 #include "chrome/common/extensions/api/automation_internal.h" |
16 #include "chrome/common/extensions/chrome_extension_messages.h" | 16 #include "chrome/common/extensions/chrome_extension_messages.h" |
17 #include "content/public/browser/notification_service.h" | 17 #include "content/public/browser/notification_service.h" |
18 #include "content/public/browser/notification_source.h" | 18 #include "content/public/browser/notification_source.h" |
19 #include "content/public/browser/notification_types.h" | 19 #include "content/public/browser/notification_types.h" |
20 #include "content/public/browser/render_process_host.h" | 20 #include "content/public/browser/render_process_host.h" |
21 #include "extensions/browser/event_router.h" | 21 #include "extensions/browser/event_router.h" |
| 22 #include "extensions/common/extension.h" |
22 #include "ui/accessibility/ax_enums.h" | 23 #include "ui/accessibility/ax_enums.h" |
23 #include "ui/accessibility/ax_node_data.h" | 24 #include "ui/accessibility/ax_node_data.h" |
24 | 25 |
25 namespace extensions { | 26 namespace extensions { |
26 | 27 |
27 // static | 28 // static |
28 AutomationEventRouter* AutomationEventRouter::GetInstance() { | 29 AutomationEventRouter* AutomationEventRouter::GetInstance() { |
29 return base::Singleton< | 30 return base::Singleton< |
30 AutomationEventRouter, | 31 AutomationEventRouter, |
31 base::LeakySingletonTraits<AutomationEventRouter>>::get(); | 32 base::LeakySingletonTraits<AutomationEventRouter>>::get(); |
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
186 // only mark one as active. | 187 // only mark one as active. |
187 listener.is_active_profile = (extension_id_count == 1 || | 188 listener.is_active_profile = (extension_id_count == 1 || |
188 rph->GetBrowserContext() == active_profile_); | 189 rph->GetBrowserContext() == active_profile_); |
189 #else | 190 #else |
190 listener.is_active_profile = true; | 191 listener.is_active_profile = true; |
191 #endif | 192 #endif |
192 } | 193 } |
193 } | 194 } |
194 | 195 |
195 } // namespace extensions | 196 } // namespace extensions |
OLD | NEW |