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

Side by Side Diff: ash/wm/workspace/workspace_window_resizer_unittest.cc

Issue 621133002: replace OVERRIDE and FINAL with override and final in ash/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
« no previous file with comments | « ash/wm/workspace/workspace_window_resizer.h ('k') | ash/wm/workspace_controller_unittest.cc » ('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) 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/workspace/workspace_window_resizer.h" 5 #include "ash/wm/workspace/workspace_window_resizer.h"
6 6
7 #include "ash/display/display_manager.h" 7 #include "ash/display/display_manager.h"
8 #include "ash/root_window_controller.h" 8 #include "ash/root_window_controller.h"
9 #include "ash/screen_util.h" 9 #include "ash/screen_util.h"
10 #include "ash/shelf/shelf_layout_manager.h" 10 #include "ash/shelf/shelf_layout_manager.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 void set_min_size(const gfx::Size& size) { 44 void set_min_size(const gfx::Size& size) {
45 min_size_ = size; 45 min_size_ = size;
46 } 46 }
47 47
48 void set_max_size(const gfx::Size& size) { 48 void set_max_size(const gfx::Size& size) {
49 max_size_ = size; 49 max_size_ = size;
50 } 50 }
51 51
52 private: 52 private:
53 // Overridden from aura::Test::TestWindowDelegate: 53 // Overridden from aura::Test::TestWindowDelegate:
54 virtual gfx::Size GetMinimumSize() const OVERRIDE { 54 virtual gfx::Size GetMinimumSize() const override {
55 return min_size_; 55 return min_size_;
56 } 56 }
57 57
58 virtual gfx::Size GetMaximumSize() const OVERRIDE { 58 virtual gfx::Size GetMaximumSize() const override {
59 return max_size_; 59 return max_size_;
60 } 60 }
61 61
62 gfx::Size min_size_; 62 gfx::Size min_size_;
63 gfx::Size max_size_; 63 gfx::Size max_size_;
64 64
65 DISALLOW_COPY_AND_ASSIGN(TestWindowDelegate); 65 DISALLOW_COPY_AND_ASSIGN(TestWindowDelegate);
66 }; 66 };
67 67
68 } // namespace 68 } // namespace
69 69
70 class WorkspaceWindowResizerTest : public test::AshTestBase { 70 class WorkspaceWindowResizerTest : public test::AshTestBase {
71 public: 71 public:
72 WorkspaceWindowResizerTest() : workspace_resizer_(NULL) {} 72 WorkspaceWindowResizerTest() : workspace_resizer_(NULL) {}
73 virtual ~WorkspaceWindowResizerTest() {} 73 virtual ~WorkspaceWindowResizerTest() {}
74 74
75 virtual void SetUp() OVERRIDE { 75 virtual void SetUp() override {
76 AshTestBase::SetUp(); 76 AshTestBase::SetUp();
77 UpdateDisplay(base::StringPrintf("800x%d", kRootHeight)); 77 UpdateDisplay(base::StringPrintf("800x%d", kRootHeight));
78 // Ignore the touch slop region. 78 // Ignore the touch slop region.
79 ui::GestureConfiguration::set_max_touch_move_in_pixels_for_click(0); 79 ui::GestureConfiguration::set_max_touch_move_in_pixels_for_click(0);
80 80
81 aura::Window* root = Shell::GetPrimaryRootWindow(); 81 aura::Window* root = Shell::GetPrimaryRootWindow();
82 gfx::Rect root_bounds(root->bounds()); 82 gfx::Rect root_bounds(root->bounds());
83 #if defined(OS_WIN) 83 #if defined(OS_WIN)
84 // RootWindow and Display can't resize on Windows Ash. 84 // RootWindow and Display can't resize on Windows Ash.
85 // http://crbug.com/165962 85 // http://crbug.com/165962
(...skipping 19 matching lines...) Expand all
105 ParentWindowInPrimaryRootWindow(window3_.get()); 105 ParentWindowInPrimaryRootWindow(window3_.get());
106 window3_->set_id(3); 106 window3_->set_id(3);
107 107
108 window4_.reset(new aura::Window(&delegate4_)); 108 window4_.reset(new aura::Window(&delegate4_));
109 window4_->SetType(ui::wm::WINDOW_TYPE_NORMAL); 109 window4_->SetType(ui::wm::WINDOW_TYPE_NORMAL);
110 window4_->Init(aura::WINDOW_LAYER_NOT_DRAWN); 110 window4_->Init(aura::WINDOW_LAYER_NOT_DRAWN);
111 ParentWindowInPrimaryRootWindow(window4_.get()); 111 ParentWindowInPrimaryRootWindow(window4_.get());
112 window4_->set_id(4); 112 window4_->set_id(4);
113 } 113 }
114 114
115 virtual void TearDown() OVERRIDE { 115 virtual void TearDown() override {
116 window_.reset(); 116 window_.reset();
117 window2_.reset(); 117 window2_.reset();
118 window3_.reset(); 118 window3_.reset();
119 window4_.reset(); 119 window4_.reset();
120 touch_resize_window_.reset(); 120 touch_resize_window_.reset();
121 AshTestBase::TearDown(); 121 AshTestBase::TearDown();
122 } 122 }
123 123
124 // Returns a string identifying the z-order of each of the known child windows 124 // Returns a string identifying the z-order of each of the known child windows
125 // of |parent|. The returned string constains the id of the known windows and 125 // of |parent|. The returned string constains the id of the known windows and
(...skipping 1754 matching lines...) Expand 10 before | Expand all | Expand 10 after
1880 // Drag even more to snap to the edge. 1880 // Drag even more to snap to the edge.
1881 generator.GestureScrollSequence(gfx::Point(400, kRootHeight - 40), 1881 generator.GestureScrollSequence(gfx::Point(400, kRootHeight - 40),
1882 gfx::Point(400, kRootHeight - 25), 1882 gfx::Point(400, kRootHeight - 25),
1883 base::TimeDelta::FromMilliseconds(10), 1883 base::TimeDelta::FromMilliseconds(10),
1884 5); 1884 5);
1885 EXPECT_EQ(gfx::Rect(100, 100, 600, kRootHeight - 100).ToString(), 1885 EXPECT_EQ(gfx::Rect(100, 100, 600, kRootHeight - 100).ToString(),
1886 touch_resize_window_->bounds().ToString()); 1886 touch_resize_window_->bounds().ToString());
1887 } 1887 }
1888 1888
1889 } // namespace ash 1889 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/workspace/workspace_window_resizer.h ('k') | ash/wm/workspace_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698