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

Side by Side Diff: views/widget/native_widget_aura.cc

Issue 8273040: Minimum size for aura window (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: addressd comment Created 9 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 | Annotate | Revision Log
« no previous file with comments | « ui/gfx/point.h ('k') | views/widget/widget.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "views/widget/native_widget_aura.h" 5 #include "views/widget/native_widget_aura.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "ui/aura/desktop.h" 8 #include "ui/aura/desktop.h"
9 #include "ui/aura/event.h" 9 #include "ui/aura/event.h"
10 #include "ui/aura/window.h" 10 #include "ui/aura/window.h"
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 // NativeWidgetAura, internal::NativeWidgetPrivate implementation: 95 // NativeWidgetAura, internal::NativeWidgetPrivate implementation:
96 96
97 void NativeWidgetAura::InitNativeWidget(const Widget::InitParams& params) { 97 void NativeWidgetAura::InitNativeWidget(const Widget::InitParams& params) {
98 ownership_ = params.ownership; 98 ownership_ = params.ownership;
99 window_->set_user_data(this); 99 window_->set_user_data(this);
100 window_->SetType(GetAuraWindowTypeFromInitParams(params)); 100 window_->SetType(GetAuraWindowTypeFromInitParams(params));
101 window_->Init(); 101 window_->Init();
102 // TODO(beng): respect |params| authoritah wrt transparency. 102 // TODO(beng): respect |params| authoritah wrt transparency.
103 window_->layer()->SetFillsBoundsOpaquely(false); 103 window_->layer()->SetFillsBoundsOpaquely(false);
104 delegate_->OnNativeWidgetCreated(); 104 delegate_->OnNativeWidgetCreated();
105 window_->set_minimum_size(delegate_->GetMinimumSize());
105 window_->SetBounds(params.bounds); 106 window_->SetBounds(params.bounds);
106 window_->SetParent( 107 window_->SetParent(
107 params.type == Widget::InitParams::TYPE_MENU ? NULL : params.parent); 108 params.type == Widget::InitParams::TYPE_MENU ? NULL : params.parent);
108 // TODO(beng): do this some other way. 109 // TODO(beng): do this some other way.
109 delegate_->OnNativeWidgetSizeChanged(params.bounds.size()); 110 delegate_->OnNativeWidgetSizeChanged(params.bounds.size());
110 can_activate_ = params.can_activate; 111 can_activate_ = params.can_activate;
111 } 112 }
112 113
113 NonClientFrameView* NativeWidgetAura::CreateNonClientFrameView() { 114 NonClientFrameView* NativeWidgetAura::CreateNonClientFrameView() {
114 NOTIMPLEMENTED(); 115 NOTIMPLEMENTED();
(...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after
653 } 654 }
654 655
655 // static 656 // static
656 bool NativeWidgetPrivate::IsMouseButtonDown() { 657 bool NativeWidgetPrivate::IsMouseButtonDown() {
657 NOTIMPLEMENTED(); 658 NOTIMPLEMENTED();
658 return false; 659 return false;
659 } 660 }
660 661
661 } // namespace internal 662 } // namespace internal
662 } // namespace views 663 } // namespace views
OLDNEW
« no previous file with comments | « ui/gfx/point.h ('k') | views/widget/widget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698