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

Side by Side Diff: chrome/browser/ui/cocoa/tabs/tab_strip_drag_controller.mm

Issue 882193003: Mac: Fix for janky tab dragging/reordering. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ValidationMessageBubble
Patch Set: Fix for rsesek Created 5 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 #import "chrome/browser/ui/cocoa/tabs/tab_strip_drag_controller.h" 5 #import "chrome/browser/ui/cocoa/tabs/tab_strip_drag_controller.h"
6 6
7 #include <Carbon/Carbon.h> 7 #include <Carbon/Carbon.h>
8 8
9 #include "base/mac/scoped_cftyperef.h" 9 #include "base/mac/scoped_cftyperef.h"
10 #import "base/mac/sdk_forward_declarations.h" 10 #import "base/mac/sdk_forward_declarations.h"
(...skipping 22 matching lines...) Expand all
33 - (NSArray*)dropTargetsForController:(TabWindowController*)dragController; 33 - (NSArray*)dropTargetsForController:(TabWindowController*)dragController;
34 - (void)setWindowBackgroundVisibility:(BOOL)shouldBeVisible; 34 - (void)setWindowBackgroundVisibility:(BOOL)shouldBeVisible;
35 - (void)endDrag:(NSEvent*)event; 35 - (void)endDrag:(NSEvent*)event;
36 - (void)continueDrag:(NSEvent*)event; 36 - (void)continueDrag:(NSEvent*)event;
37 @end 37 @end
38 38
39 //////////////////////////////////////////////////////////////////////////////// 39 ////////////////////////////////////////////////////////////////////////////////
40 40
41 @implementation TabStripDragController 41 @implementation TabStripDragController
42 42
43 @synthesize draggedTab = draggedTab_;
44
43 - (id)initWithTabStripController:(TabStripController*)controller { 45 - (id)initWithTabStripController:(TabStripController*)controller {
44 if ((self = [super init])) { 46 if ((self = [super init])) {
45 tabStrip_ = controller; 47 tabStrip_ = controller;
46 } 48 }
47 return self; 49 return self;
48 } 50 }
49 51
50 - (void)dealloc { 52 - (void)dealloc {
51 [NSObject cancelPreviousPerformRequestsWithTarget:self]; 53 [NSObject cancelPreviousPerformRequestsWithTarget:self];
52 [super dealloc]; 54 [super dealloc];
(...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after
498 [[targetController_ window] makeMainWindow]; 500 [[targetController_ window] makeMainWindow];
499 } else { 501 } else {
500 [dragWindow_ setAlphaValue:0.5]; 502 [dragWindow_ setAlphaValue:0.5];
501 [[draggedController_ overlayWindow] setHasShadow:NO]; 503 [[draggedController_ overlayWindow] setHasShadow:NO];
502 [[draggedController_ window] makeMainWindow]; 504 [[draggedController_ window] makeMainWindow];
503 } 505 }
504 chromeIsVisible_ = shouldBeVisible; 506 chromeIsVisible_ = shouldBeVisible;
505 } 507 }
506 508
507 @end 509 @end
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/tabs/tab_strip_drag_controller.h ('k') | chrome/browser/ui/cocoa/tabs/tab_view.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698