| Index: chrome/browser/ui/views/apps/chrome_native_app_window_views_mac.mm
|
| diff --git a/chrome/browser/ui/views/apps/chrome_native_app_window_views_mac.mm b/chrome/browser/ui/views/apps/chrome_native_app_window_views_mac.mm
|
| index d99a1c910dda9fd8f1e3c323e7cbad612ca73b7c..61e9657bc866338e7cfc0bf45c5620978df9974c 100644
|
| --- a/chrome/browser/ui/views/apps/chrome_native_app_window_views_mac.mm
|
| +++ b/chrome/browser/ui/views/apps/chrome_native_app_window_views_mac.mm
|
| @@ -4,9 +4,16 @@
|
|
|
| #import "chrome/browser/ui/views/apps/chrome_native_app_window_views_mac.h"
|
|
|
| +#import <Cocoa/Cocoa.h>
|
| +
|
| +#import "base/mac/scoped_nsobject.h"
|
| #include "chrome/browser/apps/app_shim/extension_app_shim_handler_mac.h"
|
| -#include "chrome/browser/ui/views/apps/app_window_native_widget_mac.h"
|
| -#include "chrome/browser/ui/views/apps/native_app_window_frame_view_mac.h"
|
| +#import "chrome/browser/ui/views/apps/app_window_native_widget_mac.h"
|
| +#import "chrome/browser/ui/views/apps/native_app_window_frame_view_mac.h"
|
| +
|
| +@interface NSView (WebContentsView)
|
| +- (void)setMouseDownCanMoveWindow:(BOOL)can_move;
|
| +@end
|
|
|
| ChromeNativeAppWindowViewsMac::ChromeNativeAppWindowViewsMac()
|
| : is_hidden_with_app_(false) {
|
| @@ -28,12 +35,12 @@ void ChromeNativeAppWindowViewsMac::OnBeforeWidgetInit(
|
|
|
| views::NonClientFrameView*
|
| ChromeNativeAppWindowViewsMac::CreateStandardDesktopAppFrame() {
|
| - return new NativeAppWindowFrameViewMac(widget());
|
| + return new NativeAppWindowFrameViewMac(widget(), this);
|
| }
|
|
|
| views::NonClientFrameView*
|
| ChromeNativeAppWindowViewsMac::CreateNonStandardAppFrame() {
|
| - return new NativeAppWindowFrameViewMac(widget());
|
| + return new NativeAppWindowFrameViewMac(widget(), this);
|
| }
|
|
|
| void ChromeNativeAppWindowViewsMac::Show() {
|
| @@ -59,6 +66,14 @@ void ChromeNativeAppWindowViewsMac::FlashFrame(bool flash) {
|
| : apps::APP_SHIM_ATTENTION_CANCEL);
|
| }
|
|
|
| +void ChromeNativeAppWindowViewsMac::UpdateDraggableRegions(
|
| + const std::vector<extensions::DraggableRegion>& regions) {
|
| + ChromeNativeAppWindowViews::UpdateDraggableRegions(regions);
|
| +
|
| + NSView* web_contents_view = app_window()->web_contents()->GetNativeView();
|
| + [web_contents_view setMouseDownCanMoveWindow:YES];
|
| +}
|
| +
|
| void ChromeNativeAppWindowViewsMac::ShowWithApp() {
|
| is_hidden_with_app_ = false;
|
| if (!app_window()->is_hidden())
|
|
|