diff options
author | jrg@chromium.org <jrg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-11-18 17:59:10 +0000 |
---|---|---|
committer | jrg@chromium.org <jrg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-11-18 17:59:10 +0000 |
commit | 52c71ed5a093463acb72598dc8b07a35fbb49842 (patch) | |
tree | 7e1705718bed27cdd1068dacb06176da3fb5b531 /chrome/browser/cocoa/bookmark_button.h | |
parent | 1308459ce571eccb2b344f35ca0e4bf750be9395 (diff) | |
download | chromium_src-52c71ed5a093463acb72598dc8b07a35fbb49842.zip chromium_src-52c71ed5a093463acb72598dc8b07a35fbb49842.tar.gz chromium_src-52c71ed5a093463acb72598dc8b07a35fbb49842.tar.bz2 |
Drag and drop of buttons/folders from bar to bar.
Does not include DnD to/from menus.
No animations of drop destination yet.
BUG=http://crbug.com/17608
TEST=Do some draggin and droppin.
Confirm click still works on the marks and folders.
Confirm "other bookmarks" canNOT be moved.
Confirm NTP / detached bar also works for DnD.
Review URL: http://codereview.chromium.org/395031
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@32341 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cocoa/bookmark_button.h')
-rw-r--r-- | chrome/browser/cocoa/bookmark_button.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/chrome/browser/cocoa/bookmark_button.h b/chrome/browser/cocoa/bookmark_button.h new file mode 100644 index 0000000..79c878a --- /dev/null +++ b/chrome/browser/cocoa/bookmark_button.h @@ -0,0 +1,23 @@ +// Copyright (c) 2009 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#import <Cocoa/Cocoa.h> + +// Class for bookmark bar buttons that can be drag sources. +@interface BookmarkButton : NSButton { + @private + BOOL draggable_; + BOOL beingDragged_; // are we being dragged? + + // Initial mouse-down to prevent a hair-trigger drag. + NSPoint initialMouseDownLocation_; +} + +// Enable or disable dragability for special buttons like "Other Bookmarks". +@property BOOL draggable; + +@end + +extern NSString* kBookmarkButtonDragType; + |