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

Side by Side Diff: chrome/browser/cocoa/bookmark_bar_controller.mm

Issue 2849026: Stop tracking a drag after the user drops the dragged item.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/cocoa/bookmark_bar_controller.h" 5 #import "chrome/browser/cocoa/bookmark_bar_controller.h"
6 #include "app/l10n_util_mac.h" 6 #include "app/l10n_util_mac.h"
7 #include "app/resource_bundle.h" 7 #include "app/resource_bundle.h"
8 #include "base/mac_util.h" 8 #include "base/mac_util.h"
9 #include "base/sys_string_conversions.h" 9 #include "base/sys_string_conversions.h"
10 #include "chrome/browser/bookmarks/bookmark_editor.h" 10 #include "chrome/browser/bookmarks/bookmark_editor.h"
(...skipping 1632 matching lines...) Expand 10 before | Expand all | Expand 10 after
1643 } 1643 }
1644 1644
1645 // Be sure we don't try and drop a folder into itself. 1645 // Be sure we don't try and drop a folder into itself.
1646 if (sourceNode != destParent) { 1646 if (sourceNode != destParent) {
1647 if (copy) 1647 if (copy)
1648 bookmarkModel_->Copy(sourceNode, destParent, destIndex); 1648 bookmarkModel_->Copy(sourceNode, destParent, destIndex);
1649 else 1649 else
1650 bookmarkModel_->Move(sourceNode, destParent, destIndex); 1650 bookmarkModel_->Move(sourceNode, destParent, destIndex);
1651 } 1651 }
1652 1652
1653 [self closeAllBookmarkFolders]; // For a hover open, if needed. 1653 [self closeFolderAndStopTrackingMenus];
1654 1654
1655 // Movement of a node triggers observers (like us) to rebuild the 1655 // Movement of a node triggers observers (like us) to rebuild the
1656 // bar so we don't have to do so explicitly. 1656 // bar so we don't have to do so explicitly.
1657 1657
1658 return YES; 1658 return YES;
1659 } 1659 }
1660 1660
1661 - (void)draggingEnded:(id<NSDraggingInfo>)info { 1661 - (void)draggingEnded:(id<NSDraggingInfo>)info {
1662 [self closeFolderAndStopTrackingMenus]; 1662 [self closeFolderAndStopTrackingMenus];
1663 } 1663 }
(...skipping 675 matching lines...) Expand 10 before | Expand all | Expand 10 after
2339 // to minimize touching the object passed in (likely a mock). 2339 // to minimize touching the object passed in (likely a mock).
2340 - (void)setButtonContextMenu:(id)menu { 2340 - (void)setButtonContextMenu:(id)menu {
2341 buttonContextMenu_ = menu; 2341 buttonContextMenu_ = menu;
2342 } 2342 }
2343 2343
2344 - (void)setIgnoreAnimations:(BOOL)ignore { 2344 - (void)setIgnoreAnimations:(BOOL)ignore {
2345 ignoreAnimations_ = ignore; 2345 ignoreAnimations_ = ignore;
2346 } 2346 }
2347 2347
2348 @end 2348 @end
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698