Chromium Code Reviews

Side by Side Diff: chrome/browser/cocoa/bookmark_bubble_controller.h

Issue 340042: bookmark STAR bubble: Disambiguate folders with the same name... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/cocoa/bookmark_bubble_controller.mm » ('j') | 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 <Cocoa/Cocoa.h> 5 #import <Cocoa/Cocoa.h>
6 #import "base/cocoa_protocols_mac.h" 6 #import "base/cocoa_protocols_mac.h"
7 #include "base/scoped_nsobject.h" 7 #include "base/scoped_nsobject.h"
8 8
9 class BookmarkModel; 9 class BookmarkModel;
10 class BookmarkNode; 10 class BookmarkNode;
(...skipping 14 matching lines...)
25 @interface BookmarkBubbleController : NSWindowController<NSWindowDelegate> { 25 @interface BookmarkBubbleController : NSWindowController<NSWindowDelegate> {
26 @private 26 @private
27 id<BookmarkBubbleControllerDelegate> delegate_; // weak like other delegates 27 id<BookmarkBubbleControllerDelegate> delegate_; // weak like other delegates
28 NSWindow* parentWindow_; // weak 28 NSWindow* parentWindow_; // weak
29 NSPoint topLeftForBubble_; 29 NSPoint topLeftForBubble_;
30 30
31 // Both weak; owned by the current browser's profile 31 // Both weak; owned by the current browser's profile
32 BookmarkModel* model_; // weak 32 BookmarkModel* model_; // weak
33 const BookmarkNode* node_; // weak 33 const BookmarkNode* node_; // weak
34 34
35 // A mapping from titles to nodes so we only have to walk this once. 35 // A mapping from NSComboBox index to parent nodes.
36 scoped_nsobject<NSMutableArray> titleMapping_; 36 scoped_nsobject<NSMutableArray> parentMapping_;
37 37
38 BOOL alreadyBookmarked_; 38 BOOL alreadyBookmarked_;
39 scoped_nsobject<NSString> chooseAnotherFolder_; 39 scoped_nsobject<NSString> chooseAnotherFolder_;
40 40
41 IBOutlet NSTextField* bigTitle_; // "Bookmark" or "Bookmark Added!" 41 IBOutlet NSTextField* bigTitle_; // "Bookmark" or "Bookmark Added!"
42 IBOutlet NSTextField* nameTextField_; 42 IBOutlet NSTextField* nameTextField_;
43 IBOutlet NSComboBox* folderComboBox_; 43 IBOutlet NSComboBox* folderComboBox_;
44 } 44 }
45 45
46 // |node| is the bookmark node we edit in this bubble. 46 // |node| is the bookmark node we edit in this bubble.
(...skipping 17 matching lines...)
64 64
65 @end 65 @end
66 66
67 67
68 // Exposed only for unit testing. 68 // Exposed only for unit testing.
69 @interface BookmarkBubbleController(ExposedForUnitTesting) 69 @interface BookmarkBubbleController(ExposedForUnitTesting)
70 - (void)fillInFolderList; 70 - (void)fillInFolderList;
71 - (void)addFolderNodes:(const BookmarkNode*)parent toComboBox:(NSComboBox*)box; 71 - (void)addFolderNodes:(const BookmarkNode*)parent toComboBox:(NSComboBox*)box;
72 - (void)updateBookmarkNode; 72 - (void)updateBookmarkNode;
73 - (void)setTitle:(NSString*)title parentFolder:(NSString*)folder; 73 - (void)setTitle:(NSString*)title parentFolder:(NSString*)folder;
74 - (void)setParentFolderSelection:(const BookmarkNode*)parent;
74 - (NSString*)chooseAnotherFolderString; 75 - (NSString*)chooseAnotherFolderString;
75 - (NSComboBox*)folderComboBox; 76 - (NSComboBox*)folderComboBox;
76 @end 77 @end
77 78
78 79
79 80
80 81
81 82
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/cocoa/bookmark_bubble_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine