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 CHROME_BROWSER_EXTENSIONS_BROWSER_EVENT_ROUTER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_BROWSER_EVENT_ROUTER_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_BROWSER_EVENT_ROUTER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_BROWSER_EVENT_ROUTER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
192 }; | 192 }; |
193 | 193 |
194 // Gets the TabEntry for the given |contents|. Returns TabEntry* if | 194 // Gets the TabEntry for the given |contents|. Returns TabEntry* if |
195 // found, NULL if not. | 195 // found, NULL if not. |
196 TabEntry* GetTabEntry(const content::WebContents* contents); | 196 TabEntry* GetTabEntry(const content::WebContents* contents); |
197 | 197 |
198 // Called when either a browser or page action is executed. Figures out which | 198 // Called when either a browser or page action is executed. Figures out which |
199 // event to send based on what the extension wants. | 199 // event to send based on what the extension wants. |
200 void ExtensionActionExecuted(Profile* profile, | 200 void ExtensionActionExecuted(Profile* profile, |
201 const ExtensionAction& extension_action, | 201 const ExtensionAction& extension_action, |
202 TabContents* tab_contents); | 202 content::WebContents* web_contents); |
203 | 203 |
204 std::map<int, TabEntry> tab_entries_; | 204 std::map<int, TabEntry> tab_entries_; |
205 | 205 |
206 // The main profile that owns this event router. | 206 // The main profile that owns this event router. |
207 Profile* profile_; | 207 Profile* profile_; |
208 | 208 |
209 DISALLOW_COPY_AND_ASSIGN(BrowserEventRouter); | 209 DISALLOW_COPY_AND_ASSIGN(BrowserEventRouter); |
210 }; | 210 }; |
211 | 211 |
212 } // namespace extensions | 212 } // namespace extensions |
213 | 213 |
214 #endif // CHROME_BROWSER_EXTENSIONS_BROWSER_EVENT_ROUTER_H_ | 214 #endif // CHROME_BROWSER_EXTENSIONS_BROWSER_EVENT_ROUTER_H_ |
OLD | NEW |