summaryrefslogtreecommitdiffstats
path: root/chrome/browser/cocoa/bookmark_bar_bridge_unittest.mm
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_bridge_unittest.mm
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_bridge_unittest.mm')
-rw-r--r--chrome/browser/cocoa/bookmark_bar_bridge_unittest.mm12
1 files changed, 7 insertions, 5 deletions
diff --git a/chrome/browser/cocoa/bookmark_bar_bridge_unittest.mm b/chrome/browser/cocoa/bookmark_bar_bridge_unittest.mm
index 2853cca..687c64a 100644
--- a/chrome/browser/cocoa/bookmark_bar_bridge_unittest.mm
+++ b/chrome/browser/cocoa/bookmark_bar_bridge_unittest.mm
@@ -26,17 +26,16 @@ typedef std::pair<GURL,WindowOpenDisposition> OpenInfo;
BookmarkBarController<BookmarkURLOpener> {
@public
scoped_nsobject<NSMutableArray> callbacks_;
-
std::vector<OpenInfo> opens_;
}
@end
@implementation FakeBookmarkBarController
-- (id)initWithProfile:(Profile*)profile
- contentArea:(NSView*)content {
+- (id)initWithProfile:(Profile*)profile view:(NSView*)view {
if ((self = [super initWithProfile:profile
- contentView:content
+ view:(BookmarkBarView*)view
+ webContentView:nil
delegate:self])) {
callbacks_.reset([[NSMutableArray alloc] init]);
}
@@ -103,9 +102,12 @@ TEST_F(BookmarkBarBridgeTest, TestRedirect) {
Profile *profile = browser_test_helper_.profile();
BookmarkModel *model = profile->GetBookmarkModel();
+ scoped_nsobject<NSView> view([[NSView alloc]
+ initWithFrame:NSMakeRect(0,0,10,10)]);
+ [view.get() setHidden:YES];
scoped_nsobject<FakeBookmarkBarController>
controller([[FakeBookmarkBarController alloc] initWithProfile:profile
- contentArea:view_]);
+ view:view.get()]);
EXPECT_TRUE(controller.get());
scoped_ptr<BookmarkBarBridge> bridge(new BookmarkBarBridge(controller.get(),
model));