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

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

Issue 10113005: Remove EPM:all_hosts_ and use all_extension_views_ instead. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: interactive_ui_tests Created 8 years, 8 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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; 16 class Extension;
17 class ExtensionHost;
18 class GURL; 17 class GURL;
19 class Profile; 18 class Profile;
20 class TabContentsWrapper; 19 class TabContentsWrapper;
21 20
22 namespace content { 21 namespace content {
23 class RenderViewHost; 22 class RenderViewHost;
24 class WebContents; 23 class WebContents;
25 } 24 }
26 25
27 namespace base { 26 namespace base {
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 IPC::Message* reply_message); 84 IPC::Message* reply_message);
86 85
87 // Sends a JSON error reply if an app modal dialog is active. Returns whether 86 // Sends a JSON error reply if an app modal dialog is active. Returns whether
88 // an error reply was sent. 87 // an error reply was sent.
89 bool SendErrorIfModalDialogActive(AutomationProvider* provider, 88 bool SendErrorIfModalDialogActive(AutomationProvider* provider,
90 IPC::Message* message); 89 IPC::Message* message);
91 90
92 // Returns a valid automation ID for the given tab. 91 // Returns a valid automation ID for the given tab.
93 AutomationId GetIdForTab(const TabContentsWrapper* tab); 92 AutomationId GetIdForTab(const TabContentsWrapper* tab);
94 93
95 // Returns a valid automation ID for the extension host. 94 // Returns a valid automation ID for the extension view.
96 AutomationId GetIdForExtensionView(const ExtensionHost* ext_host); 95 AutomationId GetIdForExtensionView(
96 const content::RenderViewHost* render_view_host);
97 97
98 // Returns a valid automation ID for the extension. 98 // Returns a valid automation ID for the extension.
99 AutomationId GetIdForExtension(const Extension* extension); 99 AutomationId GetIdForExtension(const Extension* extension);
100 100
101 // Gets the tab for the given ID. Returns true on success. 101 // Gets the tab for the given ID. Returns true on success.
102 bool GetTabForId(const AutomationId& id, content::WebContents** tab); 102 bool GetTabForId(const AutomationId& id, content::WebContents** tab);
103 103
104 // Gets the render view for the given ID. Returns true on success. 104 // Gets the render view for the given ID. Returns true on success.
105 bool GetRenderViewForId(const AutomationId& id, 105 bool GetRenderViewForId(const AutomationId& id,
106 Profile* profile, 106 Profile* profile,
107 content::RenderViewHost** rvh); 107 content::RenderViewHost** rvh);
108 108
109 // Gets the extension for the given ID. Returns true on success. 109 // Gets the extension for the given ID. Returns true on success.
110 bool GetExtensionForId(const AutomationId& id, 110 bool GetExtensionForId(const AutomationId& id,
111 Profile* profile, 111 Profile* profile,
112 const Extension** extension); 112 const Extension** extension);
113 113
114 // Returns whether the given ID refers to an actual automation entity. 114 // Returns whether the given ID refers to an actual automation entity.
115 bool DoesObjectWithIdExist(const AutomationId& id, Profile* profile); 115 bool DoesObjectWithIdExist(const AutomationId& id, Profile* profile);
116 116
117 } // namespace automation_util 117 } // namespace automation_util
118 118
119 #endif // CHROME_BROWSER_AUTOMATION_AUTOMATION_UTIL_H_ 119 #endif // CHROME_BROWSER_AUTOMATION_AUTOMATION_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698