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

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

Issue 7834048: Preliminary work to allow Chrome to build with USE_AURA (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/automation/automation_provider.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 // This implements a browser-side endpoint for UI automation activity. 5 // This implements a browser-side endpoint for UI automation activity.
6 // The client-side endpoint is implemented by AutomationProxy. 6 // The client-side endpoint is implemented by AutomationProxy.
7 // The entire lifetime of this object should be contained within that of 7 // The entire lifetime of this object should be contained within that of
8 // the BrowserProcess, and in particular the NotificationService that's 8 // the BrowserProcess, and in particular the NotificationService that's
9 // hung off of it. 9 // hung off of it.
10 10
(...skipping 13 matching lines...) Expand all
24 #include "base/string16.h" 24 #include "base/string16.h"
25 #include "chrome/browser/autofill/field_types.h" 25 #include "chrome/browser/autofill/field_types.h"
26 #include "chrome/common/automation_constants.h" 26 #include "chrome/common/automation_constants.h"
27 #include "chrome/common/content_settings.h" 27 #include "chrome/common/content_settings.h"
28 #include "content/browser/browser_thread.h" 28 #include "content/browser/browser_thread.h"
29 #include "content/browser/cancelable_request.h" 29 #include "content/browser/cancelable_request.h"
30 #include "content/browser/tab_contents/navigation_entry.h" 30 #include "content/browser/tab_contents/navigation_entry.h"
31 #include "content/common/notification_observer.h" 31 #include "content/common/notification_observer.h"
32 #include "ipc/ipc_channel.h" 32 #include "ipc/ipc_channel.h"
33 33
34 #if defined(OS_WIN) 34 #if defined(OS_WIN) && !defined(USE_AURA)
35 #include "ui/gfx/native_widget_types.h" 35 #include "ui/gfx/native_widget_types.h"
36 #include "views/events/event.h" 36 #include "views/events/event.h"
37 #endif // defined(OS_WIN) 37 #endif // defined(OS_WIN) && !defined(USE_AURA)
38 38
39 class PopupMenuWaiter; 39 class PopupMenuWaiter;
40 class TabContents; 40 class TabContents;
41 struct AutomationMsg_Find_Params; 41 struct AutomationMsg_Find_Params;
42 struct Reposition_Params; 42 struct Reposition_Params;
43 struct ExternalTabSettings; 43 struct ExternalTabSettings;
44 44
45 namespace IPC { 45 namespace IPC {
46 class ChannelProxy; 46 class ChannelProxy;
47 } 47 }
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 IPC::Message* reply_message = reply_message_; 142 IPC::Message* reply_message = reply_message_;
143 reply_message_ = NULL; 143 reply_message_ = NULL;
144 return reply_message; 144 return reply_message;
145 } 145 }
146 146
147 // Adds the extension passed in to the extension tracker, and returns 147 // Adds the extension passed in to the extension tracker, and returns
148 // the associated handle. If the tracker already contains the extension, 148 // the associated handle. If the tracker already contains the extension,
149 // the handle is simply returned. 149 // the handle is simply returned.
150 int AddExtension(const Extension* extension); 150 int AddExtension(const Extension* extension);
151 151
152 #if defined(OS_WIN) 152 #if defined(OS_WIN) && !defined(USE_AURA)
153 // Adds the external tab passed in to the tab tracker. 153 // Adds the external tab passed in to the tab tracker.
154 bool AddExternalTab(ExternalTabContainer* external_tab); 154 bool AddExternalTab(ExternalTabContainer* external_tab);
155 #endif 155 #endif
156 156
157 // Get the DictionaryValue equivalent for a download item. Caller owns the 157 // Get the DictionaryValue equivalent for a download item. Caller owns the
158 // DictionaryValue. 158 // DictionaryValue.
159 base::DictionaryValue* GetDictionaryFromDownloadItem( 159 base::DictionaryValue* GetDictionaryFromDownloadItem(
160 const DownloadItem* download); 160 const DownloadItem* download);
161 161
162 protected: 162 protected:
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
314 // the associated extension is enabled. Returns NULL otherwise. 314 // the associated extension is enabled. Returns NULL otherwise.
315 const Extension* GetEnabledExtension(int extension_handle); 315 const Extension* GetEnabledExtension(int extension_handle);
316 316
317 // Returns the extension for the given handle, if the handle is valid and 317 // Returns the extension for the given handle, if the handle is valid and
318 // the associated extension is disabled. Returns NULL otherwise. 318 // the associated extension is disabled. Returns NULL otherwise.
319 const Extension* GetDisabledExtension(int extension_handle); 319 const Extension* GetDisabledExtension(int extension_handle);
320 320
321 // Method called by the popup menu tracker when a popup menu is opened. 321 // Method called by the popup menu tracker when a popup menu is opened.
322 void NotifyPopupMenuOpened(); 322 void NotifyPopupMenuOpened();
323 323
324 #if defined(OS_WIN) 324 #if defined(OS_WIN) && !defined(USE_AURA)
325 // The functions in this block are for use with external tabs, so they are 325 // The functions in this block are for use with external tabs, so they are
326 // Windows only. 326 // Windows only.
327 327
328 // The container of an externally hosted tab calls this to reflect any 328 // The container of an externally hosted tab calls this to reflect any
329 // accelerator keys that it did not process. This gives the tab a chance 329 // accelerator keys that it did not process. This gives the tab a chance
330 // to handle the keys 330 // to handle the keys
331 void ProcessUnhandledAccelerator(const IPC::Message& message, int handle, 331 void ProcessUnhandledAccelerator(const IPC::Message& message, int handle,
332 const MSG& msg); 332 const MSG& msg);
333 333
334 void SetInitialFocus(const IPC::Message& message, int handle, bool reverse, 334 void SetInitialFocus(const IPC::Message& message, int handle, bool reverse,
(...skipping 29 matching lines...) Expand all
364 const std::string& origin, 364 const std::string& origin,
365 const std::string& target); 365 const std::string& target);
366 366
367 void OnBrowserMoved(int handle); 367 void OnBrowserMoved(int handle);
368 368
369 void OnRunUnloadHandlers(int handle, IPC::Message* reply_message); 369 void OnRunUnloadHandlers(int handle, IPC::Message* reply_message);
370 370
371 void OnSetZoomLevel(int handle, int zoom_level); 371 void OnSetZoomLevel(int handle, int zoom_level);
372 372
373 ExternalTabContainer* GetExternalTabForHandle(int handle); 373 ExternalTabContainer* GetExternalTabForHandle(int handle);
374 #endif // defined(OS_WIN) 374 #endif // defined(OS_WIN) && !defined(USE_AURA)
375 375
376 scoped_ptr<IPC::ChannelProxy> channel_; 376 scoped_ptr<IPC::ChannelProxy> channel_;
377 scoped_ptr<NotificationObserver> new_tab_ui_load_observer_; 377 scoped_ptr<NotificationObserver> new_tab_ui_load_observer_;
378 scoped_ptr<NotificationObserver> find_in_page_observer_; 378 scoped_ptr<NotificationObserver> find_in_page_observer_;
379 scoped_ptr<ExtensionTestResultNotificationObserver> 379 scoped_ptr<ExtensionTestResultNotificationObserver>
380 extension_test_result_observer_; 380 extension_test_result_observer_;
381 scoped_ptr<AutomationExtensionTracker> extension_tracker_; 381 scoped_ptr<AutomationExtensionTracker> extension_tracker_;
382 382
383 // True iff connected to an AutomationProxy. 383 // True iff connected to an AutomationProxy.
384 bool is_connected_; 384 bool is_connected_;
385 385
386 // True iff browser finished loading initial set of tabs. 386 // True iff browser finished loading initial set of tabs.
387 bool initial_tab_loads_complete_; 387 bool initial_tab_loads_complete_;
388 388
389 // True iff the Chrome OS network library finished initialization. 389 // True iff the Chrome OS network library finished initialization.
390 bool network_library_initialized_; 390 bool network_library_initialized_;
391 391
392 // True iff ChromeOS webui login ui is ready. 392 // True iff ChromeOS webui login ui is ready.
393 bool login_webui_ready_; 393 bool login_webui_ready_;
394 394
395 // ID of automation channel. 395 // ID of automation channel.
396 std::string channel_id_; 396 std::string channel_id_;
397 397
398 DISALLOW_COPY_AND_ASSIGN(AutomationProvider); 398 DISALLOW_COPY_AND_ASSIGN(AutomationProvider);
399 }; 399 };
400 400
401 #endif // CHROME_BROWSER_AUTOMATION_AUTOMATION_PROVIDER_H_ 401 #endif // CHROME_BROWSER_AUTOMATION_AUTOMATION_PROVIDER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/automation/automation_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698