diff options
author | kkania@chromium.org <kkania@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-04-07 22:08:38 +0000 |
---|---|---|
committer | kkania@chromium.org <kkania@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-04-07 22:08:38 +0000 |
commit | eb0bff94e83fb3d6829cc9fe01468fdce672e7c3 (patch) | |
tree | fd4c174cc8e8032ee74afd6fede881883dabf982 /chrome/common | |
parent | 4aa70db622005c8041be5228a628167a17e3b019 (diff) | |
download | chromium_src-eb0bff94e83fb3d6829cc9fe01468fdce672e7c3.zip chromium_src-eb0bff94e83fb3d6829cc9fe01468fdce672e7c3.tar.gz chromium_src-eb0bff94e83fb3d6829cc9fe01468fdce672e7c3.tar.bz2 |
Adds TabContents/RenderView observers for automation/testing messages.
The RenderViewObserver currently sends two messages to the browser related
to tracking client redirects, which is needed for determining whether to
wait for a future navigation.
This is particularly needed to wait correctly in chromedriver for form
submissions and javascript redirects. However, timed redirects still need
to be considered.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/6676136
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80848 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common')
-rw-r--r-- | chrome/common/automation_messages_internal.h | 18 | ||||
-rw-r--r-- | chrome/common/chrome_switches.cc | 6 |
2 files changed, 23 insertions, 1 deletions
diff --git a/chrome/common/automation_messages_internal.h b/chrome/common/automation_messages_internal.h index 58d9830..694314d 100644 --- a/chrome/common/automation_messages_internal.h +++ b/chrome/common/automation_messages_internal.h @@ -1469,3 +1469,21 @@ IPC_SYNC_MESSAGE_CONTROL1_2(AutomationMsg_GetParentBrowserOfTab, // None expected IPC_MESSAGE_ROUTED1(AutomationMsg_MoveWindow, gfx::Rect /* window position and dimentions */) + +// Renderer -> browser messages. + +// Sent when the renderer has scheduled a client redirect to occur. +IPC_MESSAGE_ROUTED2(AutomationMsg_WillPerformClientRedirect, + int64 /* frame_id */, + double /* # of seconds till redirect will be performed */) + +// Sent when the renderer has completed or canceled a client redirect for a +// particular frame. This message may be sent multiple times for the same +// redirect. +IPC_MESSAGE_ROUTED1(AutomationMsg_DidCompleteOrCancelClientRedirect, + int64 /* frame_id */) + + +// YOUR NEW MESSAGE MIGHT NOT BELONG HERE. +// This is the section for renderer -> browser automation messages. If it is +// an automation <-> browser message, put it above this section. diff --git a/chrome/common/chrome_switches.cc b/chrome/common/chrome_switches.cc index 9334281..6a08e18 100644 --- a/chrome/common/chrome_switches.cc +++ b/chrome/common/chrome_switches.cc @@ -372,10 +372,14 @@ const char kDnsPrefetchDisable[] = "dns-prefetch-disable"; // Use the specified DNS server for raw DNS resolution. const char kDnsServer[] = "dns-server"; -// Specifies if the dom_automation_controller_ needs to be bound in the +// Specifies if the |DOMAutomationController| needs to be bound in the // renderer. This binding happens on per-frame basis and hence can potentially // be a performance bottleneck. One should only enable it when automating // dom based tests. +// Also enables sending/receiving renderer automation messages through the +// |AutomationRenderViewHelper|. +// TODO(kkania): Rename this to enable-renderer-automation after moving the +// |DOMAutomationController| to the |AutomationRenderViewHelper|. const char kDomAutomationController[] = "dom-automation"; // Dump any accumualted histograms to the log when browser terminates (requires |