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

Side by Side Diff: ash/wm/panels/panel_frame_view.cc

Issue 623613004: Revert of Make WindowState::CanMinimize() take into account WidgetDelegate::CanMinimize() (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/test/ash_test_base.cc ('k') | ash/wm/system_gesture_event_filter_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/panels/panel_frame_view.h" 5 #include "ash/wm/panels/panel_frame_view.h"
6 6
7 #include "ash/frame/caption_buttons/frame_caption_button_container_view.h" 7 #include "ash/frame/caption_buttons/frame_caption_button_container_view.h"
8 #include "ash/frame/default_header_painter.h" 8 #include "ash/frame/default_header_painter.h"
9 #include "ash/frame/frame_border_hit_test_controller.h" 9 #include "ash/frame/frame_border_hit_test_controller.h"
10 #include "ui/base/hit_test.h" 10 #include "ui/base/hit_test.h"
(...skipping 21 matching lines...) Expand all
32 PanelFrameView::~PanelFrameView() { 32 PanelFrameView::~PanelFrameView() {
33 } 33 }
34 34
35 const char* PanelFrameView::GetClassName() const { 35 const char* PanelFrameView::GetClassName() const {
36 return kViewClassName; 36 return kViewClassName;
37 } 37 }
38 38
39 void PanelFrameView::InitHeaderPainter() { 39 void PanelFrameView::InitHeaderPainter() {
40 header_painter_.reset(new DefaultHeaderPainter); 40 header_painter_.reset(new DefaultHeaderPainter);
41 41
42 caption_button_container_ = new FrameCaptionButtonContainerView(frame_); 42 caption_button_container_ = new FrameCaptionButtonContainerView(frame_,
43 FrameCaptionButtonContainerView::MINIMIZE_ALLOWED);
43 AddChildView(caption_button_container_); 44 AddChildView(caption_button_container_);
44 45
45 header_painter_->Init(frame_, this, caption_button_container_); 46 header_painter_->Init(frame_, this, caption_button_container_);
46 47
47 if (frame_->widget_delegate()->ShouldShowWindowIcon()) { 48 if (frame_->widget_delegate()->ShouldShowWindowIcon()) {
48 window_icon_ = new views::ImageView(); 49 window_icon_ = new views::ImageView();
49 AddChildView(window_icon_); 50 AddChildView(window_icon_);
50 header_painter_->UpdateLeftHeaderView(window_icon_); 51 header_painter_->UpdateLeftHeaderView(window_icon_);
51 } 52 }
52 } 53 }
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 } 125 }
125 126
126 gfx::Rect PanelFrameView::GetWindowBoundsForClientBounds( 127 gfx::Rect PanelFrameView::GetWindowBoundsForClientBounds(
127 const gfx::Rect& client_bounds) const { 128 const gfx::Rect& client_bounds) const {
128 gfx::Rect window_bounds = client_bounds; 129 gfx::Rect window_bounds = client_bounds;
129 window_bounds.Inset(0, -NonClientTopBorderHeight(), 0, 0); 130 window_bounds.Inset(0, -NonClientTopBorderHeight(), 0, 0);
130 return window_bounds; 131 return window_bounds;
131 } 132 }
132 133
133 } // namespace ash 134 } // namespace ash
OLDNEW
« no previous file with comments | « ash/test/ash_test_base.cc ('k') | ash/wm/system_gesture_event_filter_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698