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

Side by Side Diff: ash/shell/toplevel_window.cc

Issue 2390953004: WidgetDelegateView is its own contents view. (Closed)
Patch Set: another minor fix Created 4 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
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/shell/toplevel_window.h" 5 #include "ash/shell/toplevel_window.h"
6 6
7 #include "ash/common/wm/window_positioner.h" 7 #include "ash/common/wm/window_positioner.h"
8 #include "ash/common/wm/window_state.h" 8 #include "ash/common/wm/window_state.h"
9 #include "ash/shell.h" 9 #include "ash/shell.h"
10 #include "ash/wm/window_state_aura.h" 10 #include "ash/wm/window_state_aura.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 *show_state = saved_state->show_state; 80 *show_state = saved_state->show_state;
81 } else { 81 } else {
82 // Initial default bounds. 82 // Initial default bounds.
83 bounds->SetRect(10, 150, 300, 300); 83 bounds->SetRect(10, 150, 300, 300);
84 } 84 }
85 WindowPositioner::GetBoundsAndShowStateForNewWindow( 85 WindowPositioner::GetBoundsAndShowStateForNewWindow(
86 nullptr, is_saved_bounds, *show_state, bounds, show_state); 86 nullptr, is_saved_bounds, *show_state, bounds, show_state);
87 return true; 87 return true;
88 } 88 }
89 89
90 views::View* ToplevelWindow::GetContentsView() {
91 return this;
92 }
93
94 bool ToplevelWindow::CanResize() const { 90 bool ToplevelWindow::CanResize() const {
95 return params_.can_resize; 91 return params_.can_resize;
96 } 92 }
97 93
98 bool ToplevelWindow::CanMaximize() const { 94 bool ToplevelWindow::CanMaximize() const {
99 return params_.can_maximize; 95 return params_.can_maximize;
100 } 96 }
101 97
102 bool ToplevelWindow::CanMinimize() const { 98 bool ToplevelWindow::CanMinimize() const {
103 return params_.can_maximize; 99 return params_.can_maximize;
104 } 100 }
105 101
106 } // namespace shell 102 } // namespace shell
107 } // namespace ash 103 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698