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

Side by Side Diff: ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc

Issue 154783002: Honor can_activate flag in ShowWindowWithState (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More review comments Created 6 years, 7 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 "ui/views/widget/desktop_aura/desktop_window_tree_host_win.h" 5 #include "ui/views/widget/desktop_aura/desktop_window_tree_host_win.h"
6 6
7 #include "base/win/metro.h" 7 #include "base/win/metro.h"
8 #include "third_party/skia/include/core/SkPath.h" 8 #include "third_party/skia/include/core/SkPath.h"
9 #include "third_party/skia/include/core/SkRegion.h" 9 #include "third_party/skia/include/core/SkRegion.h"
10 #include "ui/aura/client/aura_constants.h" 10 #include "ui/aura/client/aura_constants.h"
(...skipping 593 matching lines...) Expand 10 before | Expand all | Expand 10 after
604 bool DesktopWindowTreeHostWin::WidgetSizeIsClientSize() const { 604 bool DesktopWindowTreeHostWin::WidgetSizeIsClientSize() const {
605 const Widget* widget = GetWidget()->GetTopLevelWidget(); 605 const Widget* widget = GetWidget()->GetTopLevelWidget();
606 return IsMaximized() || (widget && widget->ShouldUseNativeFrame()); 606 return IsMaximized() || (widget && widget->ShouldUseNativeFrame());
607 } 607 }
608 608
609 bool DesktopWindowTreeHostWin::IsModal() const { 609 bool DesktopWindowTreeHostWin::IsModal() const {
610 return native_widget_delegate_->IsModal(); 610 return native_widget_delegate_->IsModal();
611 } 611 }
612 612
613 int DesktopWindowTreeHostWin::GetInitialShowState() const { 613 int DesktopWindowTreeHostWin::GetInitialShowState() const {
614 return SW_SHOWNORMAL; 614 return CanActivate() ? SW_SHOWNORMAL : SW_SHOWNOACTIVATE;
615 } 615 }
616 616
617 bool DesktopWindowTreeHostWin::WillProcessWorkAreaChange() const { 617 bool DesktopWindowTreeHostWin::WillProcessWorkAreaChange() const {
618 return GetWidget()->widget_delegate()->WillProcessWorkAreaChange(); 618 return GetWidget()->widget_delegate()->WillProcessWorkAreaChange();
619 } 619 }
620 620
621 int DesktopWindowTreeHostWin::GetNonClientComponent( 621 int DesktopWindowTreeHostWin::GetNonClientComponent(
622 const gfx::Point& point) const { 622 const gfx::Point& point) const {
623 gfx::Point dip_position = gfx::win::ScreenToDIPPoint(point); 623 gfx::Point dip_position = gfx::win::ScreenToDIPPoint(point);
624 return native_widget_delegate_->GetNonClientComponent(dip_position); 624 return native_widget_delegate_->GetNonClientComponent(dip_position);
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after
958 958
959 // static 959 // static
960 DesktopWindowTreeHost* DesktopWindowTreeHost::Create( 960 DesktopWindowTreeHost* DesktopWindowTreeHost::Create(
961 internal::NativeWidgetDelegate* native_widget_delegate, 961 internal::NativeWidgetDelegate* native_widget_delegate,
962 DesktopNativeWidgetAura* desktop_native_widget_aura) { 962 DesktopNativeWidgetAura* desktop_native_widget_aura) {
963 return new DesktopWindowTreeHostWin(native_widget_delegate, 963 return new DesktopWindowTreeHostWin(native_widget_delegate,
964 desktop_native_widget_aura); 964 desktop_native_widget_aura);
965 } 965 }
966 966
967 } // namespace views 967 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/touchui/touch_selection_controller_impl.h ('k') | ui/views/widget/widget_interactive_uitest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698