summaryrefslogtreecommitdiffstats
path: root/chrome/browser/cocoa/tab_strip_view.mm
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/cocoa/tab_strip_view.mm')
-rw-r--r--chrome/browser/cocoa/tab_strip_view.mm23
1 files changed, 23 insertions, 0 deletions
diff --git a/chrome/browser/cocoa/tab_strip_view.mm b/chrome/browser/cocoa/tab_strip_view.mm
index f2638dc..1dcd746 100644
--- a/chrome/browser/cocoa/tab_strip_view.mm
+++ b/chrome/browser/cocoa/tab_strip_view.mm
@@ -16,6 +16,9 @@
// Set lastMouseUp_ = -1000.0 so that timestamp-lastMouseUp_ is big unless
// lastMouseUp_ has been reset.
lastMouseUp_ = -1000.0;
+
+ // Register to be an URL drop target.
+ dropHandler_.reset([[URLDropTargetHandler alloc] initWithView:self]);
}
return self;
}
@@ -72,4 +75,24 @@
lastMouseUp_ = (clickCount == 1) ? timestamp : -1000.0;
}
+// Required by |URLDropTargetHandler|.
+- (NSDragOperation)draggingEntered:(id<NSDraggingInfo>)sender {
+ return [dropHandler_ draggingEntered:sender];
+}
+
+// Required by |URLDropTargetHandler|.
+- (NSDragOperation)draggingUpdated:(id<NSDraggingInfo>)sender {
+ return [dropHandler_ draggingUpdated:sender];
+}
+
+// Required by |URLDropTargetHandler|.
+- (void)draggingExited:(id<NSDraggingInfo>)sender {
+ return [dropHandler_ draggingExited:sender];
+}
+
+// Required by |URLDropTargetHandler|.
+- (BOOL)performDragOperation:(id<NSDraggingInfo>)sender {
+ return [dropHandler_ performDragOperation:sender];
+}
+
@end