OLD | NEW |
---|---|
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 <Cocoa/Cocoa.h> | 5 #import <Cocoa/Cocoa.h> |
6 #include <vector> | 6 #include <vector> |
7 #import "chrome/browser/ui/cocoa/draggable_button.h" | 7 #import "chrome/browser/ui/cocoa/draggable_button.h" |
8 #import "chrome/browser/ui/cocoa/themed_window.h" | 8 #import "chrome/browser/ui/cocoa/themed_window.h" |
9 #include "ui/base/window_open_disposition.h" | 9 #include "ui/base/window_open_disposition.h" |
10 | 10 |
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
183 - (void)removeButton:(NSInteger)buttonIndex animate:(BOOL)poof; | 183 - (void)removeButton:(NSInteger)buttonIndex animate:(BOOL)poof; |
184 | 184 |
185 // Determine the controller containing the button representing |node|, if any. | 185 // Determine the controller containing the button representing |node|, if any. |
186 - (id<BookmarkButtonControllerProtocol>)controllerForNode: | 186 - (id<BookmarkButtonControllerProtocol>)controllerForNode: |
187 (const bookmarks::BookmarkNode*)node; | 187 (const bookmarks::BookmarkNode*)node; |
188 | 188 |
189 @end // @protocol BookmarkButtonControllerProtocol | 189 @end // @protocol BookmarkButtonControllerProtocol |
190 | 190 |
191 | 191 |
192 // Class for bookmark bar buttons that can be drag sources. | 192 // Class for bookmark bar buttons that can be drag sources. |
193 @interface BookmarkButton : DraggableButton<ThemedWindowDrawing> { | 193 @interface BookmarkButton : DraggableButton<NSDraggingSource> { |
Avi (use Gerrit)
2016/03/18 21:41:03
Are we not implementing that interface any more? I
erikchen
2016/03/18 22:20:35
oops! Accidentally removed this line in a recent c
| |
194 @private | 194 @private |
195 IBOutlet NSObject<BookmarkButtonDelegate>* delegate_; // Weak. | 195 IBOutlet NSObject<BookmarkButtonDelegate>* delegate_; // Weak. |
196 | 196 |
197 // Saved pointer to the BWC for the browser window that contains this button. | 197 // Saved pointer to the BWC for the browser window that contains this button. |
198 // Used to lock and release bar visibility during a drag. The pointer is | 198 // Used to lock and release bar visibility during a drag. The pointer is |
199 // saved because the bookmark button is no longer a part of a window at the | 199 // saved because the bookmark button is no longer a part of a window at the |
200 // end of a drag operation (or, in fact, can be dragged to a completely | 200 // end of a drag operation (or, in fact, can be dragged to a completely |
201 // different window), so there is no way to retrieve the same BWC object after | 201 // different window), so there is no way to retrieve the same BWC object after |
202 // a drag. | 202 // a drag. |
203 BrowserWindowController* visibilityDelegate_; // weak | 203 BrowserWindowController* visibilityDelegate_; // weak |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
245 + (BookmarkButton*)draggedButton; | 245 + (BookmarkButton*)draggedButton; |
246 | 246 |
247 | 247 |
248 @end // @interface BookmarkButton | 248 @end // @interface BookmarkButton |
249 | 249 |
250 | 250 |
251 @interface BookmarkButton(TestingAPI) | 251 @interface BookmarkButton(TestingAPI) |
252 - (void)beginDrag:(NSEvent*)event; | 252 - (void)beginDrag:(NSEvent*)event; |
253 @end | 253 @end |
254 | 254 |
OLD | NEW |