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

Side by Side Diff: chrome/browser/ui/views/apps/native_app_window_views.cc

Issue 148093008: Create a dialog that warns about possible UI-oddities of the multi-profiles window teleport (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 10 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "chrome/browser/ui/views/apps/native_app_window_views.h" 5 #include "chrome/browser/ui/views/apps/native_app_window_views.h"
6 6
7 #include "apps/shell_window.h" 7 #include "apps/shell_window.h"
8 #include "apps/ui/views/shell_window_frame_view.h" 8 #include "apps/ui/views/shell_window_frame_view.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/file_util.h" 10 #include "base/file_util.h"
(...skipping 565 matching lines...) Expand 10 before | Expand all | Expand 10 after
576 } 576 }
577 577
578 void NativeAppWindowViews::SetAlwaysOnTop(bool always_on_top) { 578 void NativeAppWindowViews::SetAlwaysOnTop(bool always_on_top) {
579 window_->SetAlwaysOnTop(always_on_top); 579 window_->SetAlwaysOnTop(always_on_top);
580 } 580 }
581 581
582 void NativeAppWindowViews::ShowContextMenuForView( 582 void NativeAppWindowViews::ShowContextMenuForView(
583 views::View* source, 583 views::View* source,
584 const gfx::Point& p, 584 const gfx::Point& p,
585 ui::MenuSourceType source_type) { 585 ui::MenuSourceType source_type) {
586 #if defined(USE_ASH) 586 #if defined(USE_ASH) & defined(OS_CHROMEOS)
587 scoped_ptr<ui::MenuModel> model = CreateMultiUserContextMenu( 587 scoped_ptr<ui::MenuModel> model = CreateMultiUserContextMenu(
588 shell_window_->GetNativeWindow()); 588 shell_window_->GetNativeWindow());
589 if (!model.get()) 589 if (!model.get())
590 return; 590 return;
591 591
592 // Only show context menu if point is in caption. 592 // Only show context menu if point is in caption.
593 gfx::Point point_in_view_coords(p); 593 gfx::Point point_in_view_coords(p);
594 views::View::ConvertPointFromScreen(window_->non_client_view(), 594 views::View::ConvertPointFromScreen(window_->non_client_view(),
595 &point_in_view_coords); 595 &point_in_view_coords);
596 int hit_test = window_->non_client_view()->NonClientHitTest( 596 int hit_test = window_->non_client_view()->NonClientHitTest(
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after
969 gfx::Rect client_bounds = gfx::Rect(1000, 1000); 969 gfx::Rect client_bounds = gfx::Rect(1000, 1000);
970 gfx::Rect window_bounds = 970 gfx::Rect window_bounds =
971 window_->non_client_view()->GetWindowBoundsForClientBounds( 971 window_->non_client_view()->GetWindowBoundsForClientBounds(
972 client_bounds); 972 client_bounds);
973 return window_bounds.InsetsFrom(client_bounds); 973 return window_bounds.InsetsFrom(client_bounds);
974 } 974 }
975 975
976 void NativeAppWindowViews::HideWithApp() {} 976 void NativeAppWindowViews::HideWithApp() {}
977 void NativeAppWindowViews::ShowWithApp() {} 977 void NativeAppWindowViews::ShowWithApp() {}
978 void NativeAppWindowViews::UpdateWindowMinMaxSize() {} 978 void NativeAppWindowViews::UpdateWindowMinMaxSize() {}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698