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

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

Issue 55303006: Make sure the non browser/non app widget is fully visible when created on ash (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 | « ash/wm/window_state.cc ('k') | chrome/browser/ui/views/chrome_views_delegate.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) 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 "ash/display/display_layout.h" 7 #include "ash/display/display_layout.h"
8 #include "ash/display/display_manager.h" 8 #include "ash/display/display_manager.h"
9 #include "ash/root_window_controller.h" 9 #include "ash/root_window_controller.h"
10 #include "ash/screen_ash.h" 10 #include "ash/screen_ash.h"
(...skipping 15 matching lines...) Expand all
26 namespace { 26 namespace {
27 27
28 class MaximizeDelegateView : public views::WidgetDelegateView { 28 class MaximizeDelegateView : public views::WidgetDelegateView {
29 public: 29 public:
30 MaximizeDelegateView(const gfx::Rect& initial_bounds) 30 MaximizeDelegateView(const gfx::Rect& initial_bounds)
31 : initial_bounds_(initial_bounds) { 31 : initial_bounds_(initial_bounds) {
32 } 32 }
33 virtual ~MaximizeDelegateView() {} 33 virtual ~MaximizeDelegateView() {}
34 34
35 virtual bool GetSavedWindowPlacement( 35 virtual bool GetSavedWindowPlacement(
36 const views::Widget* widget,
36 gfx::Rect* bounds, 37 gfx::Rect* bounds,
37 ui::WindowShowState* show_state) const OVERRIDE { 38 ui::WindowShowState* show_state) const OVERRIDE {
38 *bounds = initial_bounds_; 39 *bounds = initial_bounds_;
39 *show_state = ui::SHOW_STATE_MAXIMIZED; 40 *show_state = ui::SHOW_STATE_MAXIMIZED;
40 return true; 41 return true;
41 } 42 }
42 43
43 private: 44 private:
44 const gfx::Rect initial_bounds_; 45 const gfx::Rect initial_bounds_;
45 46
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 window->bounds().ToString()); 401 window->bounds().ToString());
401 402
402 // Directly setting the bounds triggers a slightly different code path. Verify 403 // Directly setting the bounds triggers a slightly different code path. Verify
403 // that too. 404 // that too.
404 window->SetBounds(window_bounds); 405 window->SetBounds(window_bounds);
405 EXPECT_EQ(gfx::Rect(gfx::Point(100, 101), work_area).ToString(), 406 EXPECT_EQ(gfx::Rect(gfx::Point(100, 101), work_area).ToString(),
406 window->bounds().ToString()); 407 window->bounds().ToString());
407 } 408 }
408 409
409 } // namespace ash 410 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/window_state.cc ('k') | chrome/browser/ui/views/chrome_views_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698