| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/chrome_native_app_window_views.h" | 5 #include "chrome/browser/ui/views/apps/chrome_native_app_window_views.h" |
| 6 | 6 |
| 7 #include "apps/ui/views/app_window_frame_view.h" | 7 #include "apps/ui/views/app_window_frame_view.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "chrome/app/chrome_command_ids.h" | 9 #include "chrome/app/chrome_command_ids.h" |
| 10 #include "chrome/browser/app_mode/app_mode_utils.h" | 10 #include "chrome/browser/app_mode/app_mode_utils.h" |
| (...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 497 ash::PanelFrameView::FRAME_NONE : ash::PanelFrameView::FRAME_ASH; | 497 ash::PanelFrameView::FRAME_NONE : ash::PanelFrameView::FRAME_ASH; |
| 498 views::NonClientFrameView* frame_view = | 498 views::NonClientFrameView* frame_view = |
| 499 new ash::PanelFrameView(widget, frame_type); | 499 new ash::PanelFrameView(widget, frame_type); |
| 500 frame_view->set_context_menu_controller(this); | 500 frame_view->set_context_menu_controller(this); |
| 501 return frame_view; | 501 return frame_view; |
| 502 } | 502 } |
| 503 | 503 |
| 504 if (!IsFrameless()) { | 504 if (!IsFrameless()) { |
| 505 ash::CustomFrameViewAsh* custom_frame_view = | 505 ash::CustomFrameViewAsh* custom_frame_view = |
| 506 new ash::CustomFrameViewAsh(widget); | 506 new ash::CustomFrameViewAsh(widget); |
| 507 #if defined(OS_CHROMEOS) | |
| 508 // Non-frameless app windows can be put into immersive fullscreen. | 507 // Non-frameless app windows can be put into immersive fullscreen. |
| 509 // TODO(pkotwicz): Investigate if immersive fullscreen can be enabled for | |
| 510 // Windows Ash. | |
| 511 immersive_fullscreen_controller_.reset( | 508 immersive_fullscreen_controller_.reset( |
| 512 new ash::ImmersiveFullscreenController()); | 509 new ash::ImmersiveFullscreenController()); |
| 513 custom_frame_view->InitImmersiveFullscreenControllerForView( | 510 custom_frame_view->InitImmersiveFullscreenControllerForView( |
| 514 immersive_fullscreen_controller_.get()); | 511 immersive_fullscreen_controller_.get()); |
| 515 #endif | |
| 516 custom_frame_view->GetHeaderView()->set_context_menu_controller(this); | 512 custom_frame_view->GetHeaderView()->set_context_menu_controller(this); |
| 517 return custom_frame_view; | 513 return custom_frame_view; |
| 518 } | 514 } |
| 519 } | 515 } |
| 520 #endif | 516 #endif |
| 521 if (!ShouldUseNativeFrame()) | 517 if (!ShouldUseNativeFrame()) |
| 522 return CreateAppWindowFrameView(); | 518 return CreateAppWindowFrameView(); |
| 523 return views::WidgetDelegateView::CreateNonClientFrameView(widget); | 519 return views::WidgetDelegateView::CreateNonClientFrameView(widget); |
| 524 } | 520 } |
| 525 | 521 |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 677 NULL)); | 673 NULL)); |
| 678 | 674 |
| 679 #if defined(OS_WIN) | 675 #if defined(OS_WIN) |
| 680 if (!ShouldUseNativeFrame() && | 676 if (!ShouldUseNativeFrame() && |
| 681 chrome::GetHostDesktopTypeForNativeWindow(window()->GetNativeWindow()) != | 677 chrome::GetHostDesktopTypeForNativeWindow(window()->GetNativeWindow()) != |
| 682 chrome::HOST_DESKTOP_TYPE_ASH) { | 678 chrome::HOST_DESKTOP_TYPE_ASH) { |
| 683 InstallEasyResizeTargeterOnContainer(); | 679 InstallEasyResizeTargeterOnContainer(); |
| 684 } | 680 } |
| 685 #endif | 681 #endif |
| 686 } | 682 } |
| OLD | NEW |