diff options
author | erg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-01 18:17:23 +0000 |
---|---|---|
committer | erg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-01 18:17:23 +0000 |
commit | 363680faae60b8ec1f6a57d3c701935a6f046fb6 (patch) | |
tree | 4530c2be35fbe1dfe384ffe03e8775993fa8f4fb /chrome | |
parent | 1693996df25b186a4523e9148fd8a5fe0405ccde (diff) | |
download | chromium_src-363680faae60b8ec1f6a57d3c701935a6f046fb6.zip chromium_src-363680faae60b8ec1f6a57d3c701935a6f046fb6.tar.gz chromium_src-363680faae60b8ec1f6a57d3c701935a6f046fb6.tar.bz2 |
Refactor automation messages.
automation_messages used to live in chrome/test/automation, when it's needed by
browser and chrome_frame. When I started lifting code out of headers and into
implementation files, I was getting link errors and temporarily solved the
problem by compiling the cc files manually into libbrowser.a. Now this is part
of chrome/common/ which is included by all targets needed.
While doing this, discover that automation IPC redefines the ContextMenuParams struct. Rename it to MiniContextMenuParams.
BUG=51409
TEST=none
Review URL: http://codereview.chromium.org/4200007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@64637 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
51 files changed, 151 insertions, 164 deletions
diff --git a/chrome/browser/automation/automation_provider.cc b/chrome/browser/automation/automation_provider.cc index 60ed6ef..502b495 100644 --- a/chrome/browser/automation/automation_provider.cc +++ b/chrome/browser/automation/automation_provider.cc @@ -85,6 +85,7 @@ #include "chrome/browser/tab_contents/tab_contents_view.h" #include "chrome/browser/translate/translate_infobar_delegate.h" #include "chrome/common/automation_constants.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/chrome_constants.h" #include "chrome/common/chrome_paths.h" #include "chrome/common/chrome_switches.h" @@ -95,7 +96,6 @@ #include "chrome/common/notification_service.h" #include "chrome/common/pref_names.h" #include "chrome/common/url_constants.h" -#include "chrome/test/automation/automation_messages.h" #include "chrome/test/automation/tab_proxy.h" #include "net/proxy/proxy_service.h" #include "net/proxy/proxy_config_service_fixed.h" diff --git a/chrome/browser/automation/automation_provider.h b/chrome/browser/automation/automation_provider.h index 66d084a..8e23454 100644 --- a/chrome/browser/automation/automation_provider.h +++ b/chrome/browser/automation/automation_provider.h @@ -23,9 +23,9 @@ #include "chrome/browser/autofill/field_types.h" #include "chrome/browser/cancelable_request.h" #include "chrome/browser/tab_contents/navigation_entry.h" +#include "chrome/common/automation_constants.h" #include "chrome/common/content_settings.h" #include "chrome/common/notification_observer.h" -#include "chrome/test/automation/automation_constants.h" #include "ipc/ipc_message.h" #include "ipc/ipc_channel.h" #if defined(OS_WIN) diff --git a/chrome/browser/automation/automation_provider_gtk.cc b/chrome/browser/automation/automation_provider_gtk.cc index 37c4fb8..bf6a15c 100644 --- a/chrome/browser/automation/automation_provider_gtk.cc +++ b/chrome/browser/automation/automation_provider_gtk.cc @@ -13,7 +13,7 @@ #include "chrome/browser/gtk/browser_window_gtk.h" #include "chrome/browser/gtk/gtk_util.h" #include "chrome/browser/gtk/view_id_util.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #include "gfx/point.h" #include "gfx/rect.h" diff --git a/chrome/browser/automation/automation_provider_json.cc b/chrome/browser/automation/automation_provider_json.cc index c58b622..16fd8d4 100644 --- a/chrome/browser/automation/automation_provider_json.cc +++ b/chrome/browser/automation/automation_provider_json.cc @@ -8,7 +8,7 @@ #include "base/json/string_escape.h" #include "chrome/browser/autocomplete/autocomplete_match.h" #include "chrome/browser/automation/automation_provider.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" namespace { diff --git a/chrome/browser/automation/automation_provider_mac.mm b/chrome/browser/automation/automation_provider_mac.mm index 99c1bdb..451e7f1 100644 --- a/chrome/browser/automation/automation_provider_mac.mm +++ b/chrome/browser/automation/automation_provider_mac.mm @@ -14,7 +14,7 @@ #include "chrome/browser/cocoa/tab_window_controller.h" #include "chrome/browser/view_ids.h" #import "chrome/browser/cocoa/browser_window_controller.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #include "gfx/point.h" #include "gfx/rect.h" #include "grit/generated_resources.h" diff --git a/chrome/browser/automation/automation_provider_observers.cc b/chrome/browser/automation/automation_provider_observers.cc index 7cfa96f..174cc42 100644 --- a/chrome/browser/automation/automation_provider_observers.cc +++ b/chrome/browser/automation/automation_provider_observers.cc @@ -35,9 +35,9 @@ #include "chrome/browser/tab_contents/tab_contents.h" #include "chrome/browser/translate/page_translated_details.h" #include "chrome/browser/translate/translate_infobar_delegate.h" +#include "chrome/common/automation_constants.h" #include "chrome/common/extensions/extension.h" #include "chrome/common/notification_service.h" -#include "chrome/test/automation/automation_constants.h" #include "gfx/rect.h" #if defined(OS_CHROMEOS) diff --git a/chrome/browser/automation/automation_provider_observers.h b/chrome/browser/automation/automation_provider_observers.h index 7b76638..708d0c4 100644 --- a/chrome/browser/automation/automation_provider_observers.h +++ b/chrome/browser/automation/automation_provider_observers.h @@ -21,10 +21,10 @@ #include "chrome/browser/password_manager/password_store.h" #include "chrome/browser/search_engines/template_url_model_observer.h" #include "chrome/browser/tabs/tab_strip_model.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/notification_observer.h" #include "chrome/common/notification_registrar.h" #include "chrome/common/notification_type.h" -#include "chrome/test/automation/automation_messages.h" class AutocompleteEditModel; class AutomationProvider; diff --git a/chrome/browser/automation/automation_provider_win.cc b/chrome/browser/automation/automation_provider_win.cc index 7843c83..8c12135 100644 --- a/chrome/browser/automation/automation_provider_win.cc +++ b/chrome/browser/automation/automation_provider_win.cc @@ -22,8 +22,8 @@ #include "chrome/browser/renderer_host/render_view_host.h" #include "chrome/browser/tab_contents/tab_contents.h" #include "chrome/browser/views/bookmark_bar_view.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/page_zoom.h" -#include "chrome/test/automation/automation_messages.h" #include "views/focus/accelerator_handler.h" #include "views/widget/root_view.h" #include "views/widget/widget_win.h" diff --git a/chrome/browser/automation/automation_resource_message_filter.cc b/chrome/browser/automation/automation_resource_message_filter.cc index ecbbddc..98461d7 100644 --- a/chrome/browser/automation/automation_resource_message_filter.cc +++ b/chrome/browser/automation/automation_resource_message_filter.cc @@ -15,8 +15,8 @@ #include "chrome/browser/net/url_request_slow_download_job.h" #include "chrome/browser/net/url_request_slow_http_job.h" #include "chrome/browser/renderer_host/resource_message_filter.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/chrome_paths.h" -#include "chrome/test/automation/automation_messages.h" #include "googleurl/src/gurl.h" #include "net/base/net_errors.h" #include "net/url_request/url_request_filter.h" diff --git a/chrome/browser/automation/automation_resource_tracker.cc b/chrome/browser/automation/automation_resource_tracker.cc index a82265d..49797c6e 100644 --- a/chrome/browser/automation/automation_resource_tracker.cc +++ b/chrome/browser/automation/automation_resource_tracker.cc @@ -4,8 +4,8 @@ #include "chrome/browser/automation/automation_resource_tracker.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/notification_service.h" -#include "chrome/test/automation/automation_messages.h" AutomationResourceTrackerImpl::AutomationResourceTrackerImpl( IPC::Message::Sender* sender) diff --git a/chrome/browser/automation/chrome_frame_automation_provider.cc b/chrome/browser/automation/chrome_frame_automation_provider.cc index b3ea659..4de788a 100644 --- a/chrome/browser/automation/chrome_frame_automation_provider.cc +++ b/chrome/browser/automation/chrome_frame_automation_provider.cc @@ -5,7 +5,7 @@ #include "chrome/browser/automation/chrome_frame_automation_provider.h" #include "chrome/browser/profile.h" #include "chrome/browser/profile_manager.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #include "ipc/ipc_message.h" #include "ipc/ipc_channel.h" diff --git a/chrome/browser/automation/extension_port_container.cc b/chrome/browser/automation/extension_port_container.cc index f6b502e..5c030c4 100644 --- a/chrome/browser/automation/extension_port_container.cc +++ b/chrome/browser/automation/extension_port_container.cc @@ -15,9 +15,9 @@ #include "chrome/browser/profile.h" #include "chrome/browser/renderer_host/render_process_host.h" #include "chrome/browser/renderer_host/render_view_host.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/notification_service.h" #include "chrome/common/render_messages.h" -#include "chrome/test/automation/automation_messages.h" // TODO(siggi): Find a more structured way to read and write JSON messages. diff --git a/chrome/browser/automation/testing_automation_provider.cc b/chrome/browser/automation/testing_automation_provider.cc index 241a4b1..6d22ba4 100644 --- a/chrome/browser/automation/testing_automation_provider.cc +++ b/chrome/browser/automation/testing_automation_provider.cc @@ -65,7 +65,7 @@ #include "chrome/browser/notifications/balloon_collection.h" #include "chrome/browser/notifications/notification.h" #include "chrome/browser/notifications/notification_ui_manager.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #include "net/base/cookie_store.h" #include "net/url_request/url_request_context.h" #include "views/event.h" @@ -1352,7 +1352,7 @@ void TestingAutomationProvider::GetSecurityState(int handle, void TestingAutomationProvider::GetPageType( int handle, bool* success, - NavigationEntry::PageType* page_type) { + PageType* page_type) { if (tab_tracker_->ContainsHandle(handle)) { NavigationController* tab = tab_tracker_->GetResource(handle); NavigationEntry* entry = tab->GetActiveEntry(); @@ -1360,12 +1360,12 @@ void TestingAutomationProvider::GetPageType( *success = true; // In order to return the proper result when an interstitial is shown and // no navigation entry were created for it we need to ask the TabContents. - if (*page_type == NavigationEntry::NORMAL_PAGE && + if (*page_type == NORMAL_PAGE && tab->tab_contents()->showing_interstitial_page()) - *page_type = NavigationEntry::INTERSTITIAL_PAGE; + *page_type = INTERSTITIAL_PAGE; } else { *success = false; - *page_type = NavigationEntry::NORMAL_PAGE; + *page_type = NORMAL_PAGE; } } @@ -1383,7 +1383,7 @@ void TestingAutomationProvider::ActionOnSSLBlockingPage( if (tab_tracker_->ContainsHandle(handle)) { NavigationController* tab = tab_tracker_->GetResource(handle); NavigationEntry* entry = tab->GetActiveEntry(); - if (entry->page_type() == NavigationEntry::INTERSTITIAL_PAGE) { + if (entry->page_type() == INTERSTITIAL_PAGE) { TabContents* tab_contents = tab->tab_contents(); InterstitialPage* ssl_blocking_page = InterstitialPage::GetInterstitialPage(tab_contents); @@ -2458,10 +2458,10 @@ void TestingAutomationProvider::GetNavigationInfo( return_value->Set("ssl", ssl); // Page type. - std::map<NavigationEntry::PageType, std::string> pagetype_to_string; - pagetype_to_string[NavigationEntry::NORMAL_PAGE] = "NORMAL_PAGE"; - pagetype_to_string[NavigationEntry::ERROR_PAGE] = "ERROR_PAGE"; - pagetype_to_string[NavigationEntry::INTERSTITIAL_PAGE] = "INTERSTITIAL_PAGE"; + std::map<PageType, std::string> pagetype_to_string; + pagetype_to_string[NORMAL_PAGE] = "NORMAL_PAGE"; + pagetype_to_string[ERROR_PAGE] = "ERROR_PAGE"; + pagetype_to_string[INTERSTITIAL_PAGE] = "INTERSTITIAL_PAGE"; return_value->SetString("page_type", pagetype_to_string[nav_entry->page_type()]); diff --git a/chrome/browser/automation/testing_automation_provider.h b/chrome/browser/automation/testing_automation_provider.h index dc76603..309db74 100644 --- a/chrome/browser/automation/testing_automation_provider.h +++ b/chrome/browser/automation/testing_automation_provider.h @@ -11,6 +11,7 @@ #include "chrome/browser/browser_list.h" #include "chrome/browser/history/history.h" #include "chrome/common/notification_registrar.h" +#include "chrome/common/page_type.h" class DictionaryValue; class TemplateURLModel; @@ -197,8 +198,7 @@ class TestingAutomationProvider : public AutomationProvider, int* insecure_content_status); // Gets the page type for the tab associated to the specified |handle|. - void GetPageType(int handle, bool* success, - NavigationEntry::PageType* page_type); + void GetPageType(int handle, bool* success, PageType* page_type); // Gets the duration in ms of the last event matching |event_name|. // |duration_ms| is -1 if the event hasn't occurred yet. diff --git a/chrome/browser/automation/testing_automation_provider_views.cc b/chrome/browser/automation/testing_automation_provider_views.cc index 6048cd8..f8631cf 100644 --- a/chrome/browser/automation/testing_automation_provider_views.cc +++ b/chrome/browser/automation/testing_automation_provider_views.cc @@ -9,7 +9,7 @@ #include "chrome/browser/browser_window.h" #include "chrome/browser/views/frame/browser_view.h" #include "chrome/browser/views/toolbar_view.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #include "gfx/point.h" #include "views/controls/menu/menu_wrapper.h" #include "views/view.h" diff --git a/chrome/browser/automation/ui_controls_linux.cc b/chrome/browser/automation/ui_controls_linux.cc index a2dd0ae..21cd0dd 100644 --- a/chrome/browser/automation/ui_controls_linux.cc +++ b/chrome/browser/automation/ui_controls_linux.cc @@ -13,7 +13,7 @@ #include "base/message_loop.h" #include "chrome/browser/automation/ui_controls_internal.h" #include "chrome/browser/gtk/gtk_util.h" -#include "chrome/test/automation/automation_constants.h" +#include "chrome/common/automation_constants.h" #if defined(TOOLKIT_VIEWS) #include "views/view.h" diff --git a/chrome/browser/automation/url_request_automation_job.cc b/chrome/browser/automation/url_request_automation_job.cc index fc4bd63..1b73b68 100644 --- a/chrome/browser/automation/url_request_automation_job.cc +++ b/chrome/browser/automation/url_request_automation_job.cc @@ -11,7 +11,7 @@ #include "chrome/browser/renderer_host/render_view_host.h" #include "chrome/browser/renderer_host/resource_dispatcher_host.h" #include "chrome/browser/renderer_host/resource_dispatcher_host_request_info.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #include "net/base/cookie_monster.h" #include "net/base/io_buffer.h" #include "net/base/net_errors.h" diff --git a/chrome/browser/extensions/extension_uitest.cc b/chrome/browser/extensions/extension_uitest.cc index f074c9b..8688806 100644 --- a/chrome/browser/extensions/extension_uitest.cc +++ b/chrome/browser/extensions/extension_uitest.cc @@ -8,9 +8,9 @@ #include "base/values.h" #include "chrome/browser/automation/extension_automation_constants.h" #include "chrome/browser/extensions/extension_tabs_module_constants.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/chrome_switches.h" #include "chrome/common/extensions/extension.h" -#include "chrome/test/automation/automation_messages.h" #include "chrome/test/automation/automation_proxy_uitest.h" #include "chrome/test/automation/tab_proxy.h" #include "chrome/test/ui/ui_test.h" diff --git a/chrome/browser/external_tab_container_win.cc b/chrome/browser/external_tab_container_win.cc index 6496971..4707d88 100644 --- a/chrome/browser/external_tab_container_win.cc +++ b/chrome/browser/external_tab_container_win.cc @@ -30,6 +30,7 @@ #include "chrome/browser/tab_contents/tab_contents.h" #include "chrome/browser/views/page_info_bubble_view.h" #include "chrome/browser/views/tab_contents/tab_contents_container.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/bindings_policy.h" #include "chrome/common/chrome_constants.h" #include "chrome/common/render_messages.h" @@ -37,7 +38,6 @@ #include "chrome/common/native_web_keyboard_event.h" #include "chrome/common/notification_service.h" #include "chrome/common/page_transition_types.h" -#include "chrome/test/automation/automation_messages.h" #include "grit/generated_resources.h" #include "grit/locale_settings.h" #include "views/grid_layout.h" @@ -618,7 +618,7 @@ bool ExternalTabContainer::HandleContextMenu(const ContextMenuParams& params) { POINT screen_pt = { params.x, params.y }; MapWindowPoints(GetNativeView(), HWND_DESKTOP, &screen_pt, 1); - IPC::ContextMenuParams ipc_params; + IPC::MiniContextMenuParams ipc_params; ipc_params.screen_x = screen_pt.x; ipc_params.screen_y = screen_pt.y; ipc_params.link_url = params.link_url; diff --git a/chrome/browser/ssl/ssl_browser_tests.cc b/chrome/browser/ssl/ssl_browser_tests.cc index 247ae91..2e35b58 100644 --- a/chrome/browser/ssl/ssl_browser_tests.cc +++ b/chrome/browser/ssl/ssl_browser_tests.cc @@ -38,7 +38,7 @@ class SSLUITest : public InProcessBrowserTest { bool displayed_insecure_content) { NavigationEntry* entry = tab->controller().GetActiveEntry(); ASSERT_TRUE(entry); - EXPECT_EQ(NavigationEntry::NORMAL_PAGE, entry->page_type()); + EXPECT_EQ(NORMAL_PAGE, entry->page_type()); EXPECT_EQ(SECURITY_STYLE_AUTHENTICATED, entry->ssl().security_style()); EXPECT_EQ(0, entry->ssl().cert_status() & net::CERT_STATUS_ALL_ERRORS); EXPECT_EQ(displayed_insecure_content, @@ -49,7 +49,7 @@ class SSLUITest : public InProcessBrowserTest { void CheckUnauthenticatedState(TabContents* tab) { NavigationEntry* entry = tab->controller().GetActiveEntry(); ASSERT_TRUE(entry); - EXPECT_EQ(NavigationEntry::NORMAL_PAGE, entry->page_type()); + EXPECT_EQ(NORMAL_PAGE, entry->page_type()); EXPECT_EQ(SECURITY_STYLE_UNAUTHENTICATED, entry->ssl().security_style()); EXPECT_EQ(0, entry->ssl().cert_status() & net::CERT_STATUS_ALL_ERRORS); EXPECT_FALSE(entry->ssl().displayed_insecure_content()); @@ -62,8 +62,7 @@ class SSLUITest : public InProcessBrowserTest { bool interstitial) { NavigationEntry* entry = tab->controller().GetActiveEntry(); ASSERT_TRUE(entry); - EXPECT_EQ(interstitial ? NavigationEntry::INTERSTITIAL_PAGE : - NavigationEntry::NORMAL_PAGE, + EXPECT_EQ(interstitial ? INTERSTITIAL_PAGE : NORMAL_PAGE, entry->page_type()); EXPECT_EQ(SECURITY_STYLE_AUTHENTICATION_BROKEN, entry->ssl().security_style()); diff --git a/chrome/browser/tab_contents/interstitial_page.cc b/chrome/browser/tab_contents/interstitial_page.cc index ae1e078..8705e62 100644 --- a/chrome/browser/tab_contents/interstitial_page.cc +++ b/chrome/browser/tab_contents/interstitial_page.cc @@ -223,7 +223,7 @@ void InterstitialPage::Show() { NavigationEntry* entry = new NavigationEntry; entry->set_url(url_); entry->set_virtual_url(url_); - entry->set_page_type(NavigationEntry::INTERSTITIAL_PAGE); + entry->set_page_type(INTERSTITIAL_PAGE); // Give sub-classes a chance to set some states on the navigation entry. UpdateEntry(entry); diff --git a/chrome/browser/tab_contents/navigation_controller.cc b/chrome/browser/tab_contents/navigation_controller.cc index fc753c3..918a9b4 100644 --- a/chrome/browser/tab_contents/navigation_controller.cc +++ b/chrome/browser/tab_contents/navigation_controller.cc @@ -718,7 +718,7 @@ void NavigationController::RendererDidNavigateToNewPage( // Don't use the page type from the pending entry. Some interstitial page // may have set the type to interstitial. Once we commit, however, the page // type must always be normal. - new_entry->set_page_type(NavigationEntry::NORMAL_PAGE); + new_entry->set_page_type(NORMAL_PAGE); } else { new_entry = new NavigationEntry; } @@ -1200,8 +1200,7 @@ void NavigationController::InsertEntriesFrom( size_t insert_index = 0; for (int i = 0; i < max_index; i++) { // When cloning a tab, copy all entries except interstitial pages - if (source.entries_[i].get()->page_type() != - NavigationEntry::INTERSTITIAL_PAGE) { + if (source.entries_[i].get()->page_type() != INTERSTITIAL_PAGE) { entries_.insert(entries_.begin() + insert_index++, linked_ptr<NavigationEntry>( new NavigationEntry(*source.entries_[i]))); diff --git a/chrome/browser/tab_contents/navigation_controller_unittest.cc b/chrome/browser/tab_contents/navigation_controller_unittest.cc index 8732b62..81010a9 100644 --- a/chrome/browser/tab_contents/navigation_controller_unittest.cc +++ b/chrome/browser/tab_contents/navigation_controller_unittest.cc @@ -1374,8 +1374,7 @@ TEST_F(NavigationControllerTest, Interstitial) { // Now navigate somewhere with an interstitial. const GURL url2("http://bar"); controller().LoadURL(url1, GURL(), PageTransition::TYPED); - controller().pending_entry()->set_page_type( - NavigationEntry::INTERSTITIAL_PAGE); + controller().pending_entry()->set_page_type(INTERSTITIAL_PAGE); // At this point the interstitial will be displayed and the load will still // be pending. If the user continues, the load will commit. @@ -1383,8 +1382,7 @@ TEST_F(NavigationControllerTest, Interstitial) { // The page should be a normal page again. EXPECT_EQ(url2, controller().GetLastCommittedEntry()->url()); - EXPECT_EQ(NavigationEntry::NORMAL_PAGE, - controller().GetLastCommittedEntry()->page_type()); + EXPECT_EQ(NORMAL_PAGE, controller().GetLastCommittedEntry()->page_type()); } TEST_F(NavigationControllerTest, RemoveEntry) { @@ -1674,7 +1672,7 @@ TEST_F(NavigationControllerTest, CloneOmitsInterstitials) { // Add an interstitial entry. Should be deleted with controller. NavigationEntry* interstitial_entry = new NavigationEntry(); - interstitial_entry->set_page_type(NavigationEntry::INTERSTITIAL_PAGE); + interstitial_entry->set_page_type(INTERSTITIAL_PAGE); controller().AddTransientEntry(interstitial_entry); scoped_ptr<TabContents> clone(controller().tab_contents()->Clone()); diff --git a/chrome/browser/tab_contents/navigation_entry.h b/chrome/browser/tab_contents/navigation_entry.h index 9a5f6a5..ca97e02 100644 --- a/chrome/browser/tab_contents/navigation_entry.h +++ b/chrome/browser/tab_contents/navigation_entry.h @@ -10,8 +10,9 @@ #include "base/basictypes.h" #include "base/ref_counted.h" -#include "chrome/browser/tab_contents/security_style.h" +#include "chrome/common/page_type.h" #include "chrome/common/page_transition_types.h" +#include "chrome/common/security_style.h" #include "googleurl/src/gurl.h" #include "third_party/skia/include/core/SkBitmap.h" @@ -132,13 +133,6 @@ class NavigationEntry { // Copy and assignment is explicitly allowed for this class. }; - // The type of the page an entry corresponds to. Used by tests. - enum PageType { - NORMAL_PAGE = 0, - ERROR_PAGE, - INTERSTITIAL_PAGE - }; - // Favicon ------------------------------------------------------------------- // Collects the favicon related information for a NavigationEntry. diff --git a/chrome/browser/tab_contents/navigation_entry_unittest.cc b/chrome/browser/tab_contents/navigation_entry_unittest.cc index db59464..e28cf1c 100644 --- a/chrome/browser/tab_contents/navigation_entry_unittest.cc +++ b/chrome/browser/tab_contents/navigation_entry_unittest.cc @@ -134,10 +134,10 @@ TEST_F(NavigationEntryTest, NavigationEntryAccessors) { EXPECT_EQ(instance_, entry1_.get()->site_instance()); // Page type - EXPECT_EQ(NavigationEntry::NORMAL_PAGE, entry1_.get()->page_type()); - EXPECT_EQ(NavigationEntry::NORMAL_PAGE, entry2_.get()->page_type()); - entry2_.get()->set_page_type(NavigationEntry::INTERSTITIAL_PAGE); - EXPECT_EQ(NavigationEntry::INTERSTITIAL_PAGE, entry2_.get()->page_type()); + EXPECT_EQ(NORMAL_PAGE, entry1_.get()->page_type()); + EXPECT_EQ(NORMAL_PAGE, entry2_.get()->page_type()); + entry2_.get()->set_page_type(INTERSTITIAL_PAGE); + EXPECT_EQ(INTERSTITIAL_PAGE, entry2_.get()->page_type()); // Referrer EXPECT_EQ(GURL(), entry1_.get()->referrer()); diff --git a/chrome/browser/tab_contents/tab_contents.cc b/chrome/browser/tab_contents/tab_contents.cc index 288b5b6..c45d764 100644 --- a/chrome/browser/tab_contents/tab_contents.cc +++ b/chrome/browser/tab_contents/tab_contents.cc @@ -684,7 +684,7 @@ bool TabContents::ShouldDisplayURL() { // Don't hide the url in view source mode and with interstitials. NavigationEntry* entry = controller_.GetActiveEntry(); if (entry && (entry->IsViewSourceMode() || - entry->page_type() == NavigationEntry::INTERSTITIAL_PAGE)) { + entry->page_type() == INTERSTITIAL_PAGE)) { return true; } diff --git a/chrome/chrome.gyp b/chrome/chrome.gyp index 453138e..0b89518 100644 --- a/chrome/chrome.gyp +++ b/chrome/chrome.gyp @@ -1775,12 +1775,8 @@ 'sources': [ 'test/automation/autocomplete_edit_proxy.cc', 'test/automation/autocomplete_edit_proxy.h', - 'test/automation/automation_constants.h', 'test/automation/automation_handle_tracker.cc', 'test/automation/automation_handle_tracker.h', - 'test/automation/automation_messages.cc', - 'test/automation/automation_messages.h', - 'test/automation/automation_messages_internal.h', 'test/automation/automation_proxy.cc', 'test/automation/automation_proxy.h', 'test/automation/browser_proxy.cc', diff --git a/chrome/chrome_browser.gypi b/chrome/chrome_browser.gypi index c17f7dc..31e293c 100644 --- a/chrome/chrome_browser.gypi +++ b/chrome/chrome_browser.gypi @@ -3351,12 +3351,6 @@ 'browser/zygote_host_linux.cc', 'browser/zygote_main_linux.cc', - # TODO(erg): http://crbug.com/51409 These files are also specified as - # part of the automation project, but we need these definitions here, - # too, due to usage in our automation provider. - 'test/automation/automation_messages.cc', - 'test/automation/automation_messages.h', - # These files are generated by GRIT. '<(grit_out_dir)/grit/bookmark_manager_resources_map.cc', '<(grit_out_dir)/grit/shared_resources_map.cc', diff --git a/chrome/chrome_common.gypi b/chrome/chrome_common.gypi index d4ca5b6..d2e0a83 100644 --- a/chrome/chrome_common.gypi +++ b/chrome/chrome_common.gypi @@ -224,6 +224,9 @@ 'common/appcache/appcache_dispatcher.h', 'common/automation_constants.cc', 'common/automation_constants.h', + 'common/automation_messages.cc', + 'common/automation_messages.h', + 'common/automation_messages_internal.h', 'common/child_process_host.cc', 'common/child_process_host.h', 'common/chrome_descriptors.h', diff --git a/chrome/chrome_tests.gypi b/chrome/chrome_tests.gypi index 0556402..1bb8f08 100644 --- a/chrome/chrome_tests.gypi +++ b/chrome/chrome_tests.gypi @@ -6,9 +6,9 @@ 'variables' : { 'pyautolib_sources': [ 'app/chrome_dll_resource.h', + 'common/automation_constants.h', 'common/pref_names.cc', 'common/pref_names.h', - 'test/automation/automation_constants.h', 'test/automation/browser_proxy.cc', 'test/automation/browser_proxy.h', 'test/automation/tab_proxy.cc', diff --git a/chrome/common/automation_constants.h b/chrome/common/automation_constants.h index 6959af7..13b120e 100644 --- a/chrome/common/automation_constants.h +++ b/chrome/common/automation_constants.h @@ -15,6 +15,42 @@ extern const char kJSONProxyNoProxy[]; extern const char kJSONProxyPacUrl[]; extern const char kJSONProxyBypassList[]; extern const char kJSONProxyServer[]; + +// Amount of time to wait before querying the browser. +static const int kSleepTime = 250; } +// Used by AutomationProxy, declared here so that other headers don't need +// to include automation_proxy.h. +enum AutomationLaunchResult { + AUTOMATION_LAUNCH_RESULT_INVALID = -1, + AUTOMATION_SUCCESS, + AUTOMATION_TIMEOUT, + AUTOMATION_VERSION_MISMATCH, + AUTOMATION_CREATE_TAB_FAILED, + AUTOMATION_SERVER_CRASHED, +}; + +enum AutomationMsg_NavigationResponseValues { + AUTOMATION_MSG_NAVIGATION_ERROR = 0, + AUTOMATION_MSG_NAVIGATION_SUCCESS, + AUTOMATION_MSG_NAVIGATION_AUTH_NEEDED, +}; + +enum AutomationMsg_ExtensionResponseValues { + AUTOMATION_MSG_EXTENSION_INSTALL_SUCCEEDED = 0, + AUTOMATION_MSG_EXTENSION_INSTALL_FAILED +}; + +// Used in the AutomationMsg_GetExtensionProperty to identify which extension +// property should be retrieved, instead of having separate messages for each +// property. +enum AutomationMsg_ExtensionProperty { + AUTOMATION_MSG_EXTENSION_ID = 0, + AUTOMATION_MSG_EXTENSION_NAME, + AUTOMATION_MSG_EXTENSION_VERSION, + AUTOMATION_MSG_EXTENSION_BROWSER_ACTION_INDEX, +}; + + #endif // CHROME_COMMON_AUTOMATION_CONSTANTS_H__ diff --git a/chrome/test/automation/automation_messages.cc b/chrome/common/automation_messages.cc index 8c26327..df6d0e2 100644 --- a/chrome/test/automation/automation_messages.cc +++ b/chrome/common/automation_messages.cc @@ -2,8 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #define MESSAGES_INTERNAL_IMPL_FILE \ - "chrome/test/automation/automation_messages_internal.h" + "chrome/common/automation_messages_internal.h" #include "ipc/ipc_message_impl_macros.h" diff --git a/chrome/test/automation/automation_messages.h b/chrome/common/automation_messages.h index bb6d866..b4b22cd 100644 --- a/chrome/test/automation/automation_messages.h +++ b/chrome/common/automation_messages.h @@ -2,21 +2,20 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef CHROME_TEST_AUTOMATION_AUTOMATION_MESSAGES_H__ -#define CHROME_TEST_AUTOMATION_AUTOMATION_MESSAGES_H__ +#ifndef CHROME_COMMON_AUTOMATION_MESSAGES_H__ +#define CHROME_COMMON_AUTOMATION_MESSAGES_H__ #pragma once #include <string> #include "base/basictypes.h" -#include "chrome/browser/tab_contents/navigation_entry.h" -#include "chrome/browser/tab_contents/security_style.h" +#include "chrome/common/automation_constants.h" #include "chrome/common/common_param_traits.h" -#include "chrome/test/automation/automation_constants.h" +#include "chrome/common/page_type.h" +#include "chrome/common/security_style.h" #include "gfx/rect.h" #include "net/base/upload_data.h" - struct AutomationMsg_Find_Params { // Unused value, which exists only for backwards compat. int unused; @@ -199,8 +198,8 @@ struct ParamTraits<SecurityStyle> { }; template <> -struct ParamTraits<NavigationEntry::PageType> { - typedef NavigationEntry::PageType param_type; +struct ParamTraits<PageType> { + typedef PageType param_type; static void Write(Message* m, const param_type& p) { m->WriteInt(p); } @@ -208,19 +207,19 @@ struct ParamTraits<NavigationEntry::PageType> { int type; if (!m->ReadInt(iter, &type)) return false; - *p = static_cast<NavigationEntry::PageType>(type); + *p = static_cast<PageType>(type); return true; } static void Log(const param_type& p, std::string* l) { std::string control; switch (p) { - case NavigationEntry::NORMAL_PAGE: + case NORMAL_PAGE: control = "NORMAL_PAGE"; break; - case NavigationEntry::ERROR_PAGE: + case ERROR_PAGE: control = "ERROR_PAGE"; break; - case NavigationEntry::INTERSTITIAL_PAGE: + case INTERSTITIAL_PAGE: control = "INTERSTITIAL_PAGE"; break; default: @@ -520,7 +519,7 @@ struct ParamTraits<NavigationInfo> { }; // A stripped down version of ContextMenuParams in webkit/glue/context_menu.h. -struct ContextMenuParams { +struct MiniContextMenuParams { // The x coordinate for displaying the menu. int screen_x; @@ -548,10 +547,10 @@ struct ContextMenuParams { GURL frame_url; }; -// Traits for ContextMenuParams structure to pack/unpack. +// Traits for MiniContextMenuParams structure to pack/unpack. template <> -struct ParamTraits<ContextMenuParams> { - typedef ContextMenuParams param_type; +struct ParamTraits<MiniContextMenuParams> { + typedef MiniContextMenuParams param_type; static void Write(Message* m, const param_type& p) { WriteParam(m, p.screen_x); WriteParam(m, p.screen_y); @@ -639,7 +638,7 @@ struct ParamTraits<AttachExternalTabParams> { } // namespace IPC #define MESSAGES_INTERNAL_FILE \ - "chrome/test/automation/automation_messages_internal.h" + "chrome/common/automation_messages_internal.h" #include "ipc/ipc_message_macros.h" -#endif // CHROME_TEST_AUTOMATION_AUTOMATION_MESSAGES_H__ +#endif // CHROME_COMMON_AUTOMATION_MESSAGES_H__ diff --git a/chrome/test/automation/automation_messages_internal.h b/chrome/common/automation_messages_internal.h index adadf68..ab3c97c 100644 --- a/chrome/test/automation/automation_messages_internal.h +++ b/chrome/common/automation_messages_internal.h @@ -611,9 +611,8 @@ IPC_BEGIN_MESSAGES(Automation) // - int: handle of the tab // Response: // - bool: whether the operation was successful. - // - NavigationEntry::PageType: the type of the page currently displayed. - IPC_SYNC_MESSAGE_ROUTED1_2(AutomationMsg_GetPageType, int, bool, - NavigationEntry::PageType) + // - PageType: the type of the page currently displayed. + IPC_SYNC_MESSAGE_ROUTED1_2(AutomationMsg_GetPageType, int, bool, PageType) // This message simulates the user action on the SSL blocking page showing in // the specified tab. This message is only effective if an interstitial page @@ -952,7 +951,7 @@ IPC_BEGIN_MESSAGES(Automation) int /* tab_handle */, HANDLE /* source menu handle */, int /* align flags */, - IPC::ContextMenuParams /* params */) + IPC::MiniContextMenuParams /* params */) IPC_MESSAGE_ROUTED2(AutomationMsg_ForwardContextMenuCommandToChrome, int /* tab_handle */, diff --git a/chrome/common/page_type.h b/chrome/common/page_type.h new file mode 100644 index 0000000..2a2bd1a --- /dev/null +++ b/chrome/common/page_type.h @@ -0,0 +1,17 @@ +// Copyright (c) 2009 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef CHROME_COMMON_PAGE_TYPE_H_ +#define CHROME_COMMON_PAGE_TYPE_H_ +#pragma once + +// The type of the page an entry corresponds to. Used by chrome_frame and the +// automation layer to detect the state of a TabContents. +enum PageType { + NORMAL_PAGE = 0, + ERROR_PAGE, + INTERSTITIAL_PAGE +}; + +#endif // CHROME_COMMON_PAGE_TYPE_H_ diff --git a/chrome/browser/tab_contents/security_style.h b/chrome/common/security_style.h index 9694646..7d92d0e 100644 --- a/chrome/browser/tab_contents/security_style.h +++ b/chrome/common/security_style.h @@ -2,8 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef CHROME_BROWSER_TAB_CONTENTS_SECURITY_STYLE_H_ -#define CHROME_BROWSER_TAB_CONTENTS_SECURITY_STYLE_H_ +#ifndef CHROME_COMMON_SECURITY_STYLE_H_ +#define CHROME_COMMON_SECURITY_STYLE_H_ #pragma once // Various aspects of the UI change their appearance according to the security @@ -32,4 +32,4 @@ enum SecurityStyle { SECURITY_STYLE_AUTHENTICATED, }; -#endif // CHROME_BROWSER_TAB_CONTENTS_SECURITY_STYLE_H_ +#endif // CHROME_COMMON_SECURITY_STYLE_H_ diff --git a/chrome/test/automation/autocomplete_edit_proxy.cc b/chrome/test/automation/autocomplete_edit_proxy.cc index 5bfd13c..184239a 100644 --- a/chrome/test/automation/autocomplete_edit_proxy.cc +++ b/chrome/test/automation/autocomplete_edit_proxy.cc @@ -6,8 +6,8 @@ #include <vector> -#include "chrome/test/automation/automation_constants.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_constants.h" +#include "chrome/common/automation_messages.h" #include "chrome/test/automation/automation_proxy.h" using base::TimeDelta; diff --git a/chrome/test/automation/automation_constants.h b/chrome/test/automation/automation_constants.h deleted file mode 100644 index f34c0f2..0000000 --- a/chrome/test/automation/automation_constants.h +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright (c) 2009 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef CHROME_TEST_AUTOMATION_AUTOMATION_CONSTANTS_H_ -#define CHROME_TEST_AUTOMATION_AUTOMATION_CONSTANTS_H_ -#pragma once - -namespace automation { -// Amount of time to wait before querying the browser. -static const int kSleepTime = 250; -} - -// Used by AutomationProxy, declared here so that other headers don't need -// to include automation_proxy.h. -enum AutomationLaunchResult { - AUTOMATION_LAUNCH_RESULT_INVALID = -1, - AUTOMATION_SUCCESS, - AUTOMATION_TIMEOUT, - AUTOMATION_VERSION_MISMATCH, - AUTOMATION_CREATE_TAB_FAILED, - AUTOMATION_SERVER_CRASHED, -}; - -enum AutomationMsg_NavigationResponseValues { - AUTOMATION_MSG_NAVIGATION_ERROR = 0, - AUTOMATION_MSG_NAVIGATION_SUCCESS, - AUTOMATION_MSG_NAVIGATION_AUTH_NEEDED, -}; - -enum AutomationMsg_ExtensionResponseValues { - AUTOMATION_MSG_EXTENSION_INSTALL_SUCCEEDED = 0, - AUTOMATION_MSG_EXTENSION_INSTALL_FAILED -}; - -// Used in the AutomationMsg_GetExtensionProperty to identify which extension -// property should be retrieved, instead of having separate messages for each -// property. -enum AutomationMsg_ExtensionProperty { - AUTOMATION_MSG_EXTENSION_ID = 0, - AUTOMATION_MSG_EXTENSION_NAME, - AUTOMATION_MSG_EXTENSION_VERSION, - AUTOMATION_MSG_EXTENSION_BROWSER_ACTION_INDEX, -}; - -#endif // CHROME_TEST_AUTOMATION_AUTOMATION_CONSTANTS_H_ diff --git a/chrome/test/automation/automation_handle_tracker.cc b/chrome/test/automation/automation_handle_tracker.cc index ab29c2a..b5613a5 100644 --- a/chrome/test/automation/automation_handle_tracker.cc +++ b/chrome/test/automation/automation_handle_tracker.cc @@ -4,7 +4,7 @@ #include "chrome/test/automation/automation_handle_tracker.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #include "chrome/test/automation/automation_proxy.h" AutomationResourceProxy::AutomationResourceProxy( diff --git a/chrome/test/automation/automation_proxy.cc b/chrome/test/automation/automation_proxy.cc index 3f6eb64..74b7a94f 100644 --- a/chrome/test/automation/automation_proxy.cc +++ b/chrome/test/automation/automation_proxy.cc @@ -14,9 +14,9 @@ #include "base/process_util.h" #include "base/ref_counted.h" #include "base/waitable_event.h" +#include "chrome/common/automation_constants.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/chrome_version_info.h" -#include "chrome/test/automation/automation_constants.h" -#include "chrome/test/automation/automation_messages.h" #include "chrome/test/automation/browser_proxy.h" #include "chrome/test/automation/extension_proxy.h" #include "chrome/test/automation/tab_proxy.h" diff --git a/chrome/test/automation/automation_proxy.h b/chrome/test/automation/automation_proxy.h index 344c248..b54dc10 100644 --- a/chrome/test/automation/automation_proxy.h +++ b/chrome/test/automation/automation_proxy.h @@ -18,7 +18,7 @@ #include "base/thread.h" #include "base/waitable_event.h" #include "chrome/browser/browser.h" -#include "chrome/test/automation/automation_constants.h" +#include "chrome/common/automation_constants.h" #include "chrome/test/automation/automation_handle_tracker.h" #include "chrome/test/automation/browser_proxy.h" #include "gfx/native_widget_types.h" diff --git a/chrome/test/automation/automation_proxy_uitest.cc b/chrome/test/automation/automation_proxy_uitest.cc index a43c9e2..c1b41cd 100644 --- a/chrome/test/automation/automation_proxy_uitest.cc +++ b/chrome/test/automation/automation_proxy_uitest.cc @@ -17,11 +17,11 @@ #include "chrome/app/chrome_dll_resource.h" #include "chrome/browser/net/url_request_slow_http_job.h" #include "chrome/browser/view_ids.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/chrome_constants.h" #include "chrome/common/chrome_switches.h" #include "chrome/common/json_value_serializer.h" #include "chrome/test/automation/autocomplete_edit_proxy.h" -#include "chrome/test/automation/automation_messages.h" #include "chrome/test/automation/automation_proxy_uitest.h" #include "chrome/test/automation/browser_proxy.h" #include "chrome/test/automation/tab_proxy.h" diff --git a/chrome/test/automation/browser_proxy.cc b/chrome/test/automation/browser_proxy.cc index b5a89eb..88d833a 100644 --- a/chrome/test/automation/browser_proxy.cc +++ b/chrome/test/automation/browser_proxy.cc @@ -11,9 +11,9 @@ #include "base/logging.h" #include "base/platform_thread.h" #include "base/time.h" +#include "chrome/common/automation_constants.h" +#include "chrome/common/automation_messages.h" #include "chrome/test/automation/autocomplete_edit_proxy.h" -#include "chrome/test/automation/automation_constants.h" -#include "chrome/test/automation/automation_messages.h" #include "chrome/test/automation/automation_proxy.h" #include "chrome/test/automation/tab_proxy.h" #include "chrome/test/automation/window_proxy.h" diff --git a/chrome/test/automation/extension_proxy.cc b/chrome/test/automation/extension_proxy.cc index 29fd54c..4390c10 100644 --- a/chrome/test/automation/extension_proxy.cc +++ b/chrome/test/automation/extension_proxy.cc @@ -5,7 +5,7 @@ #include "chrome/test/automation/extension_proxy.h" #include "base/string_number_conversions.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_messages.h" #include "chrome/test/automation/automation_proxy.h" #include "chrome/test/automation/browser_proxy.h" #include "testing/gtest/include/gtest/gtest.h" diff --git a/chrome/test/automation/extension_proxy.h b/chrome/test/automation/extension_proxy.h index 485d469..ac4d7ec 100644 --- a/chrome/test/automation/extension_proxy.h +++ b/chrome/test/automation/extension_proxy.h @@ -9,7 +9,7 @@ #include <string> #include "base/compiler_specific.h" -#include "chrome/test/automation/automation_constants.h" +#include "chrome/common/automation_constants.h" #include "chrome/test/automation/automation_handle_tracker.h" class AutomationMessageSender; diff --git a/chrome/test/automation/tab_proxy.cc b/chrome/test/automation/tab_proxy.cc index a338de7..fbd837c 100644 --- a/chrome/test/automation/tab_proxy.cc +++ b/chrome/test/automation/tab_proxy.cc @@ -9,9 +9,8 @@ #include "base/logging.h" #include "base/string16.h" #include "base/utf_string_conversions.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/json_value_serializer.h" -#include "chrome/test/automation/automation_constants.h" -#include "chrome/test/automation/automation_messages.h" #include "chrome/test/automation/automation_proxy.h" #include "googleurl/src/gurl.h" @@ -606,7 +605,7 @@ bool TabProxy::GetSecurityState(SecurityStyle* security_style, return succeeded; } -bool TabProxy::GetPageType(NavigationEntry::PageType* type) { +bool TabProxy::GetPageType(PageType* type) { DCHECK(type); if (!is_valid()) diff --git a/chrome/test/automation/tab_proxy.h b/chrome/test/automation/tab_proxy.h index 92a80a7..c4b1ee7 100644 --- a/chrome/test/automation/tab_proxy.h +++ b/chrome/test/automation/tab_proxy.h @@ -18,9 +18,9 @@ #include "base/compiler_specific.h" #include "base/observer_list.h" #include "chrome/browser/download/save_package.h" -#include "chrome/browser/tab_contents/navigation_entry.h" -#include "chrome/browser/tab_contents/security_style.h" -#include "chrome/test/automation/automation_constants.h" +#include "chrome/common/automation_constants.h" +#include "chrome/common/page_type.h" +#include "chrome/common/security_style.h" #include "chrome/test/automation/automation_handle_tracker.h" #include "chrome/test/automation/dom_element_proxy.h" #include "chrome/test/automation/javascript_execution_controller.h" @@ -323,7 +323,7 @@ class TabProxy : public AutomationResourceProxy, // Returns the type of the page currently showing (normal, interstitial, // error). - bool GetPageType(NavigationEntry::PageType* page_type) WARN_UNUSED_RESULT; + bool GetPageType(PageType* page_type) WARN_UNUSED_RESULT; // Simulates the user action on the SSL blocking page. if |proceed| is true, // this is equivalent to clicking the 'Proceed' button, if false to 'Take me diff --git a/chrome/test/automation/window_proxy.cc b/chrome/test/automation/window_proxy.cc index 1a66edc..6774e6d 100644 --- a/chrome/test/automation/window_proxy.cc +++ b/chrome/test/automation/window_proxy.cc @@ -8,8 +8,8 @@ #include <algorithm> #include "base/logging.h" -#include "chrome/test/automation/automation_constants.h" -#include "chrome/test/automation/automation_messages.h" +#include "chrome/common/automation_constants.h" +#include "chrome/common/automation_messages.h" #include "chrome/test/automation/automation_proxy.h" #include "chrome/test/automation/browser_proxy.h" #include "chrome/test/automation/tab_proxy.h" diff --git a/chrome/test/pyautolib/pyautolib.i b/chrome/test/pyautolib/pyautolib.i index 875d530..eb4ebbe 100644 --- a/chrome/test/pyautolib/pyautolib.i +++ b/chrome/test/pyautolib/pyautolib.i @@ -27,12 +27,12 @@ // Headers that can be swigged directly. %include "chrome/app/chrome_dll_resource.h" +%include "chrome/common/automation_constants.h" %include "chrome/common/pref_names.h" -%include "chrome/test/automation/automation_constants.h" %{ +#include "chrome/common/automation_constants.h" #include "chrome/common/pref_names.h" -#include "chrome/test/automation/automation_constants.h" #include "chrome/test/automation/browser_proxy.h" #include "chrome/test/automation/tab_proxy.h" #include "chrome/test/pyautolib/pyautolib.h" diff --git a/chrome/test/reliability/page_load_test.cc b/chrome/test/reliability/page_load_test.cc index 770f0f2..571c16a 100644 --- a/chrome/test/reliability/page_load_test.cc +++ b/chrome/test/reliability/page_load_test.cc @@ -50,6 +50,7 @@ #include "chrome/browser/browser_thread.h" #include "chrome/browser/net/url_fixer_upper.h" #include "chrome/browser/prefs/pref_service.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/chrome_constants.h" #include "chrome/common/chrome_paths.h" #include "chrome/common/chrome_switches.h" @@ -58,7 +59,6 @@ #include "chrome/common/logging_chrome.h" #include "chrome/common/pref_names.h" #include "chrome/common/url_constants.h" -#include "chrome/test/automation/automation_messages.h" #include "chrome/test/automation/automation_proxy.h" #include "chrome/test/automation/browser_proxy.h" #include "chrome/test/automation/tab_proxy.h" diff --git a/chrome/test/ui/ui_test.cc b/chrome/test/ui/ui_test.cc index 8c72435..7c7deb7b 100644 --- a/chrome/test/ui/ui_test.cc +++ b/chrome/test/ui/ui_test.cc @@ -30,6 +30,7 @@ #include "base/utf_string_conversions.h" #include "chrome/app/chrome_dll_resource.h" #include "chrome/browser/net/url_fixer_upper.h" +#include "chrome/common/automation_messages.h" #include "chrome/common/chrome_constants.h" #include "chrome/common/chrome_paths.h" #include "chrome/common/chrome_switches.h" @@ -37,7 +38,6 @@ #include "chrome/common/logging_chrome.h" #include "chrome/common/json_value_serializer.h" #include "chrome/common/url_constants.h" -#include "chrome/test/automation/automation_messages.h" #include "chrome/test/automation/automation_proxy.h" #include "chrome/test/automation/browser_proxy.h" #include "chrome/test/automation/javascript_execution_controller.h" |