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

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

Issue 1050713002: aura: Remove layerless windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: layerless: rebase Created 5 years, 8 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
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_layout_manager.h" 5 #include "ash/wm/workspace/workspace_layout_manager.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "ash/display/display_layout.h" 9 #include "ash/display/display_layout.h"
10 #include "ash/display/display_manager.h" 10 #include "ash/display/display_manager.h"
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 DISALLOW_COPY_AND_ASSIGN(DontClobberRestoreBoundsWindowObserver); 336 DISALLOW_COPY_AND_ASSIGN(DontClobberRestoreBoundsWindowObserver);
337 }; 337 };
338 338
339 // Creates a window, maximized the window and from within the maximized 339 // Creates a window, maximized the window and from within the maximized
340 // notification sets the bounds of a window to overlap the shelf. Verifies this 340 // notification sets the bounds of a window to overlap the shelf. Verifies this
341 // doesn't effect the restore bounds. 341 // doesn't effect the restore bounds.
342 TEST_F(WorkspaceLayoutManagerTest, DontClobberRestoreBounds) { 342 TEST_F(WorkspaceLayoutManagerTest, DontClobberRestoreBounds) {
343 DontClobberRestoreBoundsWindowObserver window_observer; 343 DontClobberRestoreBoundsWindowObserver window_observer;
344 scoped_ptr<aura::Window> window(new aura::Window(NULL)); 344 scoped_ptr<aura::Window> window(new aura::Window(NULL));
345 window->SetType(ui::wm::WINDOW_TYPE_NORMAL); 345 window->SetType(ui::wm::WINDOW_TYPE_NORMAL);
346 window->Init(aura::WINDOW_LAYER_TEXTURED); 346 window->Init(ui::LAYER_TEXTURED);
347 window->SetBounds(gfx::Rect(10, 20, 30, 40)); 347 window->SetBounds(gfx::Rect(10, 20, 30, 40));
348 // NOTE: for this test to exercise the failure the observer needs to be added 348 // NOTE: for this test to exercise the failure the observer needs to be added
349 // before the parent set. This mimics what BrowserFrameAsh does. 349 // before the parent set. This mimics what BrowserFrameAsh does.
350 window->AddObserver(&window_observer); 350 window->AddObserver(&window_observer);
351 ParentWindowInPrimaryRootWindow(window.get()); 351 ParentWindowInPrimaryRootWindow(window.get());
352 window->Show(); 352 window->Show();
353 353
354 wm::WindowState* window_state = wm::GetWindowState(window.get()); 354 wm::WindowState* window_state = wm::GetWindowState(window.get());
355 window_state->Activate(); 355 window_state->Activate();
356 356
(...skipping 794 matching lines...) Expand 10 before | Expand all | Expand 10 after
1151 occluded_window_bounds.width(), 1151 occluded_window_bounds.width(),
1152 occluded_window_bounds.height()).ToString(), 1152 occluded_window_bounds.height()).ToString(),
1153 window->bounds().ToString()); 1153 window->bounds().ToString());
1154 HideKeyboard(); 1154 HideKeyboard();
1155 EXPECT_EQ(occluded_window_bounds.ToString(), window->bounds().ToString()); 1155 EXPECT_EQ(occluded_window_bounds.ToString(), window->bounds().ToString());
1156 1156
1157 Blur(&text_input_client); 1157 Blur(&text_input_client);
1158 } 1158 }
1159 1159
1160 } // namespace ash 1160 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/workspace/workspace_event_handler_unittest.cc ('k') | ash/wm/workspace/workspace_window_resizer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698