summaryrefslogtreecommitdiffstats
path: root/chrome/browser/cocoa/bookmark_bar_controller.h
diff options
context:
space:
mode:
authorjrg@chromium.org <jrg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-09 04:45:07 +0000
committerjrg@chromium.org <jrg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-09 04:45:07 +0000
commit152494e06591140bbf5003bba82cafa6f34962ec (patch)
treef55043335e4caed020668c25423bb0ec586b2802 /chrome/browser/cocoa/bookmark_bar_controller.h
parent1b9af295f86b846582f96277bdba05d98bc3d2f4 (diff)
downloadchromium_src-152494e06591140bbf5003bba82cafa6f34962ec.zip
chromium_src-152494e06591140bbf5003bba82cafa6f34962ec.tar.gz
chromium_src-152494e06591140bbf5003bba82cafa6f34962ec.tar.bz2
- Fix janklist issue #1: "there is a pixel line below the main
toolbar. The main toolbar should blend in with the bookmark bar when it's open" - Fix janklist issue #2: "It's way too tall - the distance from the bottom of the bar to a bookmark button bottom edge should be the same as the distance from the omnibox to the bookmark button top edge (this will probably mean that the bar has to overlap the toolbar)." - Fix janklist issue #4 (first part): "the bookmark bar bookmark buttons have a frame around them ... " - Fix janklist issue #9: "the show/hide animation is very janky... I see a dark gray area behind". Even with animators the grey is gone, but animators are disabled for now due to races. - Fix unlisted jank related to 9: don't use animator when opening bar on launch. - Also chipped away on unit tests. TEST=Launch with bookmark bar both open and closed. Make sure OK on launch. In each case open and close a few times fast. Repeat with multiple windows open. Sanity check jank descriptions listed above are fixed. BUG=crbug.com/14139, crbug.com/8381, crbug.com/14724 Review URL: http://codereview.chromium.org/149308 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20244 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cocoa/bookmark_bar_controller.h')
-rw-r--r--chrome/browser/cocoa/bookmark_bar_controller.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/chrome/browser/cocoa/bookmark_bar_controller.h b/chrome/browser/cocoa/bookmark_bar_controller.h
index d7a93d4..1993411 100644
--- a/chrome/browser/cocoa/bookmark_bar_controller.h
+++ b/chrome/browser/cocoa/bookmark_bar_controller.h
@@ -45,12 +45,10 @@ class PrefService;
BOOL barIsEnabled_;
// The view of the bookmark bar itself.
- // Not made into a scoped_nsobject since I may move it into a nib.
- // (See TODO in initWithProfile: in bookmark_bar_controller.mm).
- IBOutlet BookmarkBarView* bookmarkBarView_;
+ // Owned by the toolbar view, its parent view.
+ BookmarkBarView* bookmarkBarView_; // weak
- // The tab content area for the window (where the web goes)
- IBOutlet NSView* contentView_;
+ NSView* webContentView_; // weak; where the web goes
// Bridge from Chrome-style C++ notifications (e.g. derived from
// BookmarkModelObserver)
@@ -61,16 +59,14 @@ class PrefService;
}
// Initializes the controller with the given browser profile and
-// content view. We use |content| as a parent view for the bookmark
+// content view. We use |webContentView| as the view for the bookmark
// bar view and for geometry management. |delegate| is used for
-// opening URLs.
+// opening URLs. |view| is expected to be hidden.
- (id)initWithProfile:(Profile*)profile
- contentView:(NSView*)content
+ view:(BookmarkBarView*)view
+ webContentView:(NSView*)webContentView
delegate:(id<BookmarkURLOpener>)delegate;
-// Resizes the bookmark bar based on the state of the content area.
-- (void)resizeBookmarkBar;
-
// Returns whether or not the bookmark bar is visible.
- (BOOL)isBookmarkBarVisible;
@@ -103,10 +99,14 @@ class PrefService;
@end
-// These APIs should only be used by unit tests, in place of "friend" classes.
+// These APIs should only be used by unit tests (or used internally).
@interface BookmarkBarController(TestingAPI)
// Access to the bookmark bar's view represented by this controller.
- (NSView*)view;
+// Set the delegate for a unit test.
+- (void)setDelegate:(id<BookmarkURLOpener>)delegate;
+// Action for our bookmark buttons.
+- (void)openBookmark:(id)sender;
@end
#endif // CHROME_BROWSER_COCOA_BOOKMARK_BAR_CONTROLLER_H_