diff options
author | markusheintz@chromium.org <markusheintz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-07-24 13:18:41 +0000 |
---|---|---|
committer | markusheintz@chromium.org <markusheintz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-07-24 13:18:41 +0000 |
commit | dd131d3723dee3050b746319e437514d8fdb6bb1 (patch) | |
tree | c44435187d6d4df51dcf5e02b31be151de270390 /content | |
parent | 2c6e3b04ca361d052f1e8fdc70983bcc7c379dba (diff) | |
download | chromium_src-dd131d3723dee3050b746319e437514d8fdb6bb1.zip chromium_src-dd131d3723dee3050b746319e437514d8fdb6bb1.tar.gz chromium_src-dd131d3723dee3050b746319e437514d8fdb6bb1.tar.bz2 |
Revert 285209 "Cleanups for aura/test/event_generator.h (resolve..."
> Cleanups for aura/test/event_generator.h (resolve TODOs)
>
> Some purely mechanical changes left over from r283694, now that
> aura::test::EventGenerator has moved to ui::test in src/ui/events.
>
> Moves aura/test/event_generator.* to event_generator_delegate_aura.*
> Removes `using ui::test::EventGenerator;` declaration and redirects
> includes that don't extend the delegate to include the ui/test
> event_generator.h directly
>
> BUG=378134
>
> Review URL: https://codereview.chromium.org/406413004
TBR=tapted@chromium.org
Review URL: https://codereview.chromium.org/413983006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@285222 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
4 files changed, 21 insertions, 21 deletions
diff --git a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc index a5cf62b..2e4cab0 100644 --- a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc +++ b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc @@ -39,6 +39,7 @@ #include "ui/aura/env.h" #include "ui/aura/layout_manager.h" #include "ui/aura/test/aura_test_helper.h" +#include "ui/aura/test/event_generator.h" #include "ui/aura/test/test_cursor_client.h" #include "ui/aura/test/test_screen.h" #include "ui/aura/test/test_window_delegate.h" @@ -51,7 +52,6 @@ #include "ui/events/event.h" #include "ui/events/event_utils.h" #include "ui/events/gestures/gesture_configuration.h" -#include "ui/events/test/event_generator.h" #include "ui/wm/core/default_activation_client.h" using testing::_; @@ -715,7 +715,7 @@ TEST_F(RenderWidgetHostViewAuraTest, DestroyPopupClickOutsidePopup) { EXPECT_FALSE(parent_window->GetBoundsInRootWindow().Contains(click_point)); TestWindowObserver observer(window); - ui::test::EventGenerator generator(window->GetRootWindow(), click_point); + aura::test::EventGenerator generator(window->GetRootWindow(), click_point); generator.ClickLeftButton(); ASSERT_TRUE(parent_view_->HasFocus()); ASSERT_TRUE(observer.destroyed()); @@ -742,7 +742,7 @@ TEST_F(RenderWidgetHostViewAuraTest, DestroyPopupTapOutsidePopup) { EXPECT_FALSE(parent_window->GetBoundsInRootWindow().Contains(tap_point)); TestWindowObserver observer(window); - ui::test::EventGenerator generator(window->GetRootWindow(), tap_point); + aura::test::EventGenerator generator(window->GetRootWindow(), tap_point); generator.GestureTapAt(tap_point); ASSERT_TRUE(parent_view_->HasFocus()); ASSERT_TRUE(observer.destroyed()); diff --git a/content/browser/web_contents/aura/window_slider_unittest.cc b/content/browser/web_contents/aura/window_slider_unittest.cc index 2aaaddc..4a2d0a5 100644 --- a/content/browser/web_contents/aura/window_slider_unittest.cc +++ b/content/browser/web_contents/aura/window_slider_unittest.cc @@ -8,6 +8,7 @@ #include "base/time/time.h" #include "testing/gtest/include/gtest/gtest.h" #include "ui/aura/test/aura_test_base.h" +#include "ui/aura/test/event_generator.h" #include "ui/aura/test/test_window_delegate.h" #include "ui/aura/window.h" #include "ui/base/hit_test.h" @@ -16,7 +17,6 @@ #include "ui/compositor/test/layer_animator_test_controller.h" #include "ui/events/event_processor.h" #include "ui/events/event_utils.h" -#include "ui/events/test/event_generator.h" #include "ui/gfx/frame_time.h" namespace content { @@ -214,7 +214,7 @@ TEST_F(WindowSliderTest, WindowSlideUsingGesture) { window->SetBounds(gfx::Rect(0, 0, 400, 400)); WindowSliderDelegateTest slider_delegate; - ui::test::EventGenerator generator(root_window()); + aura::test::EventGenerator generator(root_window()); // Generate a horizontal overscroll. WindowSlider* slider = @@ -310,7 +310,7 @@ TEST_F(WindowSliderTest, WindowSlideIsCancelledOnEvent) { new WindowSlider(&slider_delegate, root_window(), window.get()); for (int i = 0; events[i]; ++i) { // Generate a horizontal overscroll. - ui::test::EventGenerator generator(root_window()); + aura::test::EventGenerator generator(root_window()); generator.GestureScrollSequenceWithCallback( gfx::Point(10, 10), gfx::Point(80, 10), @@ -352,7 +352,7 @@ TEST_F(WindowSliderTest, WindowSlideInterruptedThenContinues) { gfx::Point(55, 10), 0, 0); - ui::test::EventGenerator generator(root_window()); + aura::test::EventGenerator generator(root_window()); // Start the scroll sequence. Scroll forward so that |window|'s layer is the // one animating. @@ -452,7 +452,7 @@ TEST_F(WindowSliderTest, OwnerWindowChangesDuringWindowSlide) { // Generate a horizontal scroll, and change the owner in the middle of the // scroll. - ui::test::EventGenerator generator(root_window()); + aura::test::EventGenerator generator(root_window()); aura::Window* old_window = window.get(); generator.GestureScrollSequenceWithCallback( gfx::Point(10, 10), @@ -484,7 +484,7 @@ TEST_F(WindowSliderTest, NoSlideWhenLayerCantBeCreated) { WindowSlider* slider = new WindowSlider(&slider_delegate, root_window(), window.get()); - ui::test::EventGenerator generator(root_window()); + aura::test::EventGenerator generator(root_window()); // No slide in progress should be reported during scroll since the layer // wasn't created. @@ -530,7 +530,7 @@ TEST_F(WindowSliderTest, OwnerIsDestroyedOnSliderDestroy) { EXPECT_EQ(child_windows + 1, root_window()->children().size()); WindowSliderDeleteOwnerOnDestroy slider_delegate(window); - ui::test::EventGenerator generator(root_window()); + aura::test::EventGenerator generator(root_window()); // Generate a horizontal overscroll. scoped_ptr<WindowSlider> slider( @@ -561,7 +561,7 @@ TEST_F(WindowSliderTest, OwnerIsDestroyedOnSlideComplete) { EXPECT_EQ(child_windows + 1, root_window()->children().size()); WindowSliderDeleteOwnerOnComplete slider_delegate(window); - ui::test::EventGenerator generator(root_window()); + aura::test::EventGenerator generator(root_window()); // Generate a horizontal overscroll. new WindowSlider(&slider_delegate, root_window(), window); @@ -598,7 +598,7 @@ TEST_F(WindowSliderTest, SwipeDuringSwipeAnimation) { animator->set_disable_timer_for_test(true); ui::LayerAnimatorTestController test_controller(animator); - ui::test::EventGenerator generator(root_window()); + aura::test::EventGenerator generator(root_window()); // Swipe forward so that |window|'s layer is the one animating. generator.GestureScrollSequence( diff --git a/content/browser/web_contents/touch_editable_impl_aura_browsertest.cc b/content/browser/web_contents/touch_editable_impl_aura_browsertest.cc index 421f4ba..a44174e 100644 --- a/content/browser/web_contents/touch_editable_impl_aura_browsertest.cc +++ b/content/browser/web_contents/touch_editable_impl_aura_browsertest.cc @@ -19,12 +19,12 @@ #include "content/public/test/test_utils.h" #include "content/shell/browser/shell.h" #include "third_party/WebKit/public/web/WebInputEvent.h" +#include "ui/aura/test/event_generator.h" #include "ui/aura/window.h" #include "ui/aura/window_tree_host.h" #include "ui/base/ui_base_switches.h" #include "ui/compositor/scoped_animation_duration_scale_mode.h" #include "ui/events/event_utils.h" -#include "ui/events/test/event_generator.h" using blink::WebInputEvent; @@ -149,7 +149,7 @@ IN_PROC_BROWSER_TEST_F(TouchEditableImplAuraTest, RenderWidgetHostViewAura* rwhva = static_cast<RenderWidgetHostViewAura*>( web_contents->GetRenderWidgetHostView()); aura::Window* content = web_contents->GetContentNativeView(); - ui::test::EventGenerator generator(content->GetRootWindow(), content); + aura::test::EventGenerator generator(content->GetRootWindow(), content); gfx::Rect bounds = content->GetBoundsInRootWindow(); touch_editable->Reset(); @@ -331,7 +331,7 @@ IN_PROC_BROWSER_TEST_F(TouchEditableImplAuraTest, RenderWidgetHostViewAura* rwhva = static_cast<RenderWidgetHostViewAura*>( web_contents->GetRenderWidgetHostView()); aura::Window* content = web_contents->GetContentNativeView(); - ui::test::EventGenerator generator(content->GetRootWindow(), content); + aura::test::EventGenerator generator(content->GetRootWindow(), content); gfx::Rect bounds = content->GetBoundsInRootWindow(); EXPECT_EQ(GetRenderWidgetHostViewAura(touch_editable), rwhva); diff --git a/content/browser/web_contents/web_contents_view_aura_browsertest.cc b/content/browser/web_contents/web_contents_view_aura_browsertest.cc index 3b4ba77..673db0f 100644 --- a/content/browser/web_contents/web_contents_view_aura_browsertest.cc +++ b/content/browser/web_contents/web_contents_view_aura_browsertest.cc @@ -27,12 +27,12 @@ #include "content/public/test/test_renderer_host.h" #include "content/public/test/test_utils.h" #include "content/shell/browser/shell.h" +#include "ui/aura/test/event_generator.h" #include "ui/aura/window.h" #include "ui/aura/window_tree_host.h" #include "ui/compositor/scoped_animation_duration_scale_mode.h" #include "ui/events/event_processor.h" #include "ui/events/event_utils.h" -#include "ui/events/test/event_generator.h" namespace content { @@ -184,7 +184,7 @@ class WebContentsViewAuraTest : public ContentBrowserTest { aura::Window* content = web_contents->GetContentNativeView(); gfx::Rect bounds = content->GetBoundsInRootWindow(); - ui::test::EventGenerator generator(content->GetRootWindow(), content); + aura::test::EventGenerator generator(content->GetRootWindow(), content); const int kScrollDurationMs = 20; const int kScrollSteps = 10; @@ -448,7 +448,7 @@ IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, MAYBE_OverscrollScreenshot) { content::TitleWatcher title_watcher(web_contents, expected_title); aura::Window* content = web_contents->GetContentNativeView(); gfx::Rect bounds = content->GetBoundsInRootWindow(); - ui::test::EventGenerator generator(content->GetRootWindow(), content); + aura::test::EventGenerator generator(content->GetRootWindow(), content); generator.GestureScrollSequence( gfx::Point(bounds.x() + 2, bounds.y() + 10), gfx::Point(bounds.right() - 10, bounds.y() + 10), @@ -616,7 +616,7 @@ IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, aura::Window* content = web_contents->GetContentNativeView(); gfx::Rect bounds = content->GetBoundsInRootWindow(); - ui::test::EventGenerator generator(content->GetRootWindow(), content); + aura::test::EventGenerator generator(content->GetRootWindow(), content); generator.GestureScrollSequence( gfx::Point(bounds.x() + 2, bounds.y() + 10), gfx::Point(bounds.right() - 10, bounds.y() + 10), @@ -637,7 +637,7 @@ IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, ContentWindowClose) { aura::Window* content = web_contents->GetContentNativeView(); gfx::Rect bounds = content->GetBoundsInRootWindow(); - ui::test::EventGenerator generator(content->GetRootWindow(), content); + aura::test::EventGenerator generator(content->GetRootWindow(), content); generator.GestureScrollSequence( gfx::Point(bounds.x() + 2, bounds.y() + 10), gfx::Point(bounds.right() - 10, bounds.y() + 10), @@ -685,7 +685,7 @@ IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, aura::Window* content = web_contents->GetContentNativeView(); gfx::Rect bounds = content->GetBoundsInRootWindow(); - ui::test::EventGenerator generator(content->GetRootWindow(), content); + aura::test::EventGenerator generator(content->GetRootWindow(), content); // Do a swipe left to start a forward navigation. Then quickly do a swipe // right. |