Index: ui/views/cocoa/bridged_native_widget.h |
diff --git a/ui/views/cocoa/bridged_native_widget.h b/ui/views/cocoa/bridged_native_widget.h |
index a4e4b1d9541b779f703730e6f5d15936e02527ab..5f52831ecbbff6776393bc61fb7753c8dc3b1c1d 100644 |
--- a/ui/views/cocoa/bridged_native_widget.h |
+++ b/ui/views/cocoa/bridged_native_widget.h |
@@ -132,6 +132,12 @@ class VIEWS_EXPORT BridgedNativeWidget : public ui::LayerDelegate, |
// Called by the NSWindowDelegate when the window becomes or resigns key. |
void OnWindowKeyStatusChangedTo(bool is_key); |
+ // Called by NSWindowDelegate when the application receives a mouse-down, but |
+ // before the event is processed by NSWindows. Returning true here will cause |
+ // the event to be cancelled and reposted at the CGSessionEventTap level. This |
+ // is used to determine whether a mouse-down should drag the window. |
+ virtual bool ShouldRepostPendingLeftMouseDown(NSPoint location_in_window); |
+ |
// Called by NativeWidgetMac when the window size constraints change. |
void OnSizeConstraintsChanged(); |
@@ -191,6 +197,10 @@ class VIEWS_EXPORT BridgedNativeWidget : public ui::LayerDelegate, |
// scale factor. |
void UpdateLayerProperties(); |
+ // Sets mouseDownCanMoveWindow on |bridged_view_| and triggers the NSWindow to |
+ // update its draggable region. |
+ void SetDraggable(bool draggable); |
+ |
// Overridden from CocoaMouseCaptureDelegate: |
void PostCapturedEvent(NSEvent* event) override; |
void OnMouseCaptureLost() override; |