Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(10)

Side by Side Diff: chrome/browser/automation/automation_util.h

Issue 10375021: Move Extension into extensions namespace (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Take 6 Created 8 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_AUTOMATION_AUTOMATION_UTIL_H_ 5 #ifndef CHROME_BROWSER_AUTOMATION_AUTOMATION_UTIL_H_
6 #define CHROME_BROWSER_AUTOMATION_AUTOMATION_UTIL_H_ 6 #define CHROME_BROWSER_AUTOMATION_AUTOMATION_UTIL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
11 #include "base/basictypes.h" 11 #include "base/basictypes.h"
12 12
13 class AutomationId; 13 class AutomationId;
14 class AutomationProvider; 14 class AutomationProvider;
15 class Browser; 15 class Browser;
16 class Extension;
17 class GURL; 16 class GURL;
18 class Profile; 17 class Profile;
19 class TabContentsWrapper; 18 class TabContentsWrapper;
20 19
21 namespace content { 20 namespace content {
22 class RenderViewHost; 21 class RenderViewHost;
23 class WebContents; 22 class WebContents;
24 } 23 }
25 24
26 namespace base { 25 namespace base {
27 class DictionaryValue; 26 class DictionaryValue;
28 } 27 }
29 28
29 namespace extensions {
30 class Extension;
31 }
32
30 namespace IPC { 33 namespace IPC {
31 class Message; 34 class Message;
32 } 35 }
33 36
34 // This file contains automation utility functions. 37 // This file contains automation utility functions.
35 38
36 namespace automation_util { 39 namespace automation_util {
37 40
38 // Returns the browser at the given index of the |BrowserList| or NULL if the 41 // Returns the browser at the given index of the |BrowserList| or NULL if the
39 // index is out of range. 42 // index is out of range.
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 IPC::Message* message); 92 IPC::Message* message);
90 93
91 // Returns a valid automation ID for the given tab. 94 // Returns a valid automation ID for the given tab.
92 AutomationId GetIdForTab(const TabContentsWrapper* tab); 95 AutomationId GetIdForTab(const TabContentsWrapper* tab);
93 96
94 // Returns a valid automation ID for the extension view. 97 // Returns a valid automation ID for the extension view.
95 AutomationId GetIdForExtensionView( 98 AutomationId GetIdForExtensionView(
96 const content::RenderViewHost* render_view_host); 99 const content::RenderViewHost* render_view_host);
97 100
98 // Returns a valid automation ID for the extension. 101 // Returns a valid automation ID for the extension.
99 AutomationId GetIdForExtension(const Extension* extension); 102 AutomationId GetIdForExtension(const extensions::Extension* extension);
100 103
101 // Gets the tab for the given ID. Returns true on success. 104 // Gets the tab for the given ID. Returns true on success.
102 bool GetTabForId(const AutomationId& id, content::WebContents** tab); 105 bool GetTabForId(const AutomationId& id, content::WebContents** tab);
103 106
104 // Gets the render view for the given ID. Returns true on success. 107 // Gets the render view for the given ID. Returns true on success.
105 bool GetRenderViewForId(const AutomationId& id, 108 bool GetRenderViewForId(const AutomationId& id,
106 Profile* profile, 109 Profile* profile,
107 content::RenderViewHost** rvh); 110 content::RenderViewHost** rvh);
108 111
109 // Gets the extension for the given ID. Returns true on success. 112 // Gets the extension for the given ID. Returns true on success.
110 bool GetExtensionForId(const AutomationId& id, 113 bool GetExtensionForId(const AutomationId& id,
111 Profile* profile, 114 Profile* profile,
112 const Extension** extension); 115 const extensions::Extension** extension);
113 116
114 // Returns whether the given ID refers to an actual automation entity. 117 // Returns whether the given ID refers to an actual automation entity.
115 bool DoesObjectWithIdExist(const AutomationId& id, Profile* profile); 118 bool DoesObjectWithIdExist(const AutomationId& id, Profile* profile);
116 119
117 } // namespace automation_util 120 } // namespace automation_util
118 121
119 #endif // CHROME_BROWSER_AUTOMATION_AUTOMATION_UTIL_H_ 122 #endif // CHROME_BROWSER_AUTOMATION_AUTOMATION_UTIL_H_
OLDNEW
« no previous file with comments | « chrome/browser/automation/automation_provider_observers.cc ('k') | chrome/browser/automation/automation_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698