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

Side by Side Diff: ui/aura/window_targeter_unittest.cc

Issue 126513004: Rename RootWindowHost to WindowTreeHost (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 11 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 | « ui/aura/test/test_screen.cc ('k') | ui/aura/window_tree_host.h » ('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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 #include "ui/aura/window_targeter.h" 5 #include "ui/aura/window_targeter.h"
6 6
7 #include "ui/aura/test/aura_test_base.h" 7 #include "ui/aura/test/aura_test_base.h"
8 #include "ui/aura/test/test_event_handler.h" 8 #include "ui/aura/test/test_event_handler.h"
9 #include "ui/aura/test/test_window_delegate.h" 9 #include "ui/aura/test/test_window_delegate.h"
10 #include "ui/aura/window.h" 10 #include "ui/aura/window.h"
(...skipping 21 matching lines...) Expand all
32 root_window()->Show(); 32 root_window()->Show();
33 33
34 test::TestEventHandler handler; 34 test::TestEventHandler handler;
35 one->AddPreTargetHandler(&handler); 35 one->AddPreTargetHandler(&handler);
36 36
37 ui::MouseEvent press(ui::ET_MOUSE_PRESSED, 37 ui::MouseEvent press(ui::ET_MOUSE_PRESSED,
38 gfx::Point(20, 20), 38 gfx::Point(20, 20),
39 gfx::Point(20, 20), 39 gfx::Point(20, 20),
40 ui::EF_NONE, 40 ui::EF_NONE,
41 ui::EF_NONE); 41 ui::EF_NONE);
42 root_window()->GetDispatcher()->AsRootWindowHostDelegate()-> 42 root_window()->GetDispatcher()->AsWindowTreeHostDelegate()->
43 OnHostMouseEvent(&press); 43 OnHostMouseEvent(&press);
44 EXPECT_EQ(1, handler.num_mouse_events()); 44 EXPECT_EQ(1, handler.num_mouse_events());
45 45
46 handler.Reset(); 46 handler.Reset();
47 ui::EventDispatchDetails details = 47 ui::EventDispatchDetails details =
48 root_window()->GetDispatcher()->OnEventFromSource(&press); 48 root_window()->GetDispatcher()->OnEventFromSource(&press);
49 EXPECT_FALSE(details.dispatcher_destroyed); 49 EXPECT_FALSE(details.dispatcher_destroyed);
50 EXPECT_EQ(1, handler.num_mouse_events()); 50 EXPECT_EQ(1, handler.num_mouse_events());
51 51
52 one->RemovePreTargetHandler(&handler); 52 one->RemovePreTargetHandler(&handler);
53 } 53 }
54 54
55 } // namespace aura 55 } // namespace aura
OLDNEW
« no previous file with comments | « ui/aura/test/test_screen.cc ('k') | ui/aura/window_tree_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698