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

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_mac.mm

Issue 2658293002: content: Remove Lock/Unlock CompositingSurface API from RWH. (Closed)
Patch Set: mac Created 3 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 (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 "content/browser/renderer_host/render_widget_host_view_mac.h" 5 #include "content/browser/renderer_host/render_widget_host_view_mac.h"
6 6
7 #import <Carbon/Carbon.h> 7 #import <Carbon/Carbon.h>
8 #import <objc/runtime.h> 8 #import <objc/runtime.h>
9 #include <OpenGL/gl.h> 9 #include <OpenGL/gl.h>
10 #include <QuartzCore/QuartzCore.h> 10 #include <QuartzCore/QuartzCore.h>
(...skipping 1427 matching lines...) Expand 10 before | Expand all | Expand 10 after
1438 // the view hierarchy because the tab isn't main. Could retrieve 1438 // the view hierarchy because the tab isn't main. Could retrieve
1439 // the information from the main tab for our window. 1439 // the information from the main tab for our window.
1440 NSWindow* enclosing_window = ApparentWindowForView(cocoa_view_); 1440 NSWindow* enclosing_window = ApparentWindowForView(cocoa_view_);
1441 if (!enclosing_window) 1441 if (!enclosing_window)
1442 return gfx::Rect(); 1442 return gfx::Rect();
1443 1443
1444 NSRect bounds = [enclosing_window frame]; 1444 NSRect bounds = [enclosing_window frame];
1445 return FlipNSRectToRectScreen(bounds); 1445 return FlipNSRectToRectScreen(bounds);
1446 } 1446 }
1447 1447
1448 void RenderWidgetHostViewMac::LockCompositingSurface() {
1449 NOTIMPLEMENTED();
1450 }
1451
1452 void RenderWidgetHostViewMac::UnlockCompositingSurface() {
1453 NOTIMPLEMENTED();
1454 }
1455
1456 bool RenderWidgetHostViewMac::LockMouse() { 1448 bool RenderWidgetHostViewMac::LockMouse() {
1457 if (mouse_locked_) 1449 if (mouse_locked_)
1458 return true; 1450 return true;
1459 1451
1460 mouse_locked_ = true; 1452 mouse_locked_ = true;
1461 1453
1462 // Lock position of mouse cursor and hide it. 1454 // Lock position of mouse cursor and hide it.
1463 CGAssociateMouseAndMouseCursorPosition(NO); 1455 CGAssociateMouseAndMouseCursorPosition(NO);
1464 [NSCursor hide]; 1456 [NSCursor hide];
1465 1457
(...skipping 1981 matching lines...) Expand 10 before | Expand all | Expand 10 after
3447 3439
3448 // "-webkit-app-region: drag | no-drag" is implemented on Mac by excluding 3440 // "-webkit-app-region: drag | no-drag" is implemented on Mac by excluding
3449 // regions that are not draggable. (See ControlRegionView in 3441 // regions that are not draggable. (See ControlRegionView in
3450 // native_app_window_cocoa.mm). This requires the render host view to be 3442 // native_app_window_cocoa.mm). This requires the render host view to be
3451 // draggable by default. 3443 // draggable by default.
3452 - (BOOL)mouseDownCanMoveWindow { 3444 - (BOOL)mouseDownCanMoveWindow {
3453 return YES; 3445 return YES;
3454 } 3446 }
3455 3447
3456 @end 3448 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698