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

Side by Side Diff: ash/wm/toplevel_window_event_handler_unittest.cc

Issue 121773003: Makes Window::Init take a WindowLayerType instead of LayerType. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge to master 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ash/wm/toplevel_window_event_handler.h" 5 #include "ash/wm/toplevel_window_event_handler.h"
6 6
7 #include "ash/root_window_controller.h" 7 #include "ash/root_window_controller.h"
8 #include "ash/shell.h" 8 #include "ash/shell.h"
9 #include "ash/shell_window_ids.h" 9 #include "ash/shell_window_ids.h"
10 #include "ash/test/ash_test_base.h" 10 #include "ash/test/ash_test_base.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 public: 62 public:
63 ToplevelWindowEventHandlerTest() {} 63 ToplevelWindowEventHandlerTest() {}
64 virtual ~ToplevelWindowEventHandlerTest() {} 64 virtual ~ToplevelWindowEventHandlerTest() {}
65 65
66 protected: 66 protected:
67 aura::Window* CreateWindow(int hittest_code) { 67 aura::Window* CreateWindow(int hittest_code) {
68 TestWindowDelegate* d1 = new TestWindowDelegate(hittest_code); 68 TestWindowDelegate* d1 = new TestWindowDelegate(hittest_code);
69 aura::Window* w1 = new aura::Window(d1); 69 aura::Window* w1 = new aura::Window(d1);
70 w1->SetType(ui::wm::WINDOW_TYPE_NORMAL); 70 w1->SetType(ui::wm::WINDOW_TYPE_NORMAL);
71 w1->set_id(1); 71 w1->set_id(1);
72 w1->Init(ui::LAYER_TEXTURED); 72 w1->Init(aura::WINDOW_LAYER_TEXTURED);
73 aura::Window* parent = 73 aura::Window* parent =
74 Shell::GetContainer(Shell::GetPrimaryRootWindow(), 74 Shell::GetContainer(Shell::GetPrimaryRootWindow(),
75 internal::kShellWindowId_AlwaysOnTopContainer); 75 internal::kShellWindowId_AlwaysOnTopContainer);
76 parent->AddChild(w1); 76 parent->AddChild(w1);
77 w1->SetBounds(gfx::Rect(0, 0, 100, 100)); 77 w1->SetBounds(gfx::Rect(0, 0, 100, 100));
78 w1->Show(); 78 w1->Show();
79 return w1; 79 return w1;
80 } 80 }
81 81
82 void DragFromCenterBy(aura::Window* window, int dx, int dy) { 82 void DragFromCenterBy(aura::Window* window, int dx, int dy) {
(...skipping 630 matching lines...) Expand 10 before | Expand all | Expand 10 after
713 move_client->RunMoveLoop(window2.get(), gfx::Vector2d(), 713 move_client->RunMoveLoop(window2.get(), gfx::Vector2d(),
714 aura::client::WINDOW_MOVE_SOURCE_MOUSE); 714 aura::client::WINDOW_MOVE_SOURCE_MOUSE);
715 EXPECT_EQ(window1_initial_bounds.ToString(), window1->bounds().ToString()); 715 EXPECT_EQ(window1_initial_bounds.ToString(), window1->bounds().ToString());
716 } 716 }
717 717
718 // Showing the resize shadows when the mouse is over the window edges is tested 718 // Showing the resize shadows when the mouse is over the window edges is tested
719 // in resize_shadow_and_cursor_test.cc 719 // in resize_shadow_and_cursor_test.cc
720 720
721 } // namespace test 721 } // namespace test
722 } // namespace ash 722 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/stacking_controller_unittest.cc ('k') | ash/wm/workspace/multi_window_resize_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698