| OLD | NEW | 
|     1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |     1 // Copyright (c) 2012 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  |     6  | 
|     7 #include "base/basictypes.h" |     7 #include "base/basictypes.h" | 
|     8 #include "base/command_line.h" |     8 #include "base/command_line.h" | 
|     9 #include "base/mac/mac_util.h" |     9 #include "base/mac/mac_util.h" | 
|    10 #include "base/mac/scoped_nsobject.h" |    10 #include "base/mac/scoped_nsobject.h" | 
| (...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   283  public: |   283  public: | 
|   284   base::scoped_nsobject<NSView> parent_view_; |   284   base::scoped_nsobject<NSView> parent_view_; | 
|   285   base::scoped_nsobject<ViewResizerPong> resizeDelegate_; |   285   base::scoped_nsobject<ViewResizerPong> resizeDelegate_; | 
|   286  |   286  | 
|   287   virtual void SetUp() { |   287   virtual void SetUp() { | 
|   288     CocoaProfileTest::SetUp(); |   288     CocoaProfileTest::SetUp(); | 
|   289     ASSERT_TRUE(profile()); |   289     ASSERT_TRUE(profile()); | 
|   290  |   290  | 
|   291     base::FilePath extension_dir; |   291     base::FilePath extension_dir; | 
|   292     static_cast<extensions::TestExtensionSystem*>( |   292     static_cast<extensions::TestExtensionSystem*>( | 
|   293         extensions::ExtensionSystem::Get(profile()))-> |   293         extensions::ExtensionSystem::Get(profile())) | 
|   294         CreateExtensionService( |   294         ->CreateExtensionService(base::CommandLine::ForCurrentProcess(), | 
|   295             CommandLine::ForCurrentProcess(), |   295                                  extension_dir, false); | 
|   296             extension_dir, false); |  | 
|   297     resizeDelegate_.reset([[ViewResizerPong alloc] init]); |   296     resizeDelegate_.reset([[ViewResizerPong alloc] init]); | 
|   298     NSRect parent_frame = NSMakeRect(0, 0, 800, 50); |   297     NSRect parent_frame = NSMakeRect(0, 0, 800, 50); | 
|   299     parent_view_.reset([[NSView alloc] initWithFrame:parent_frame]); |   298     parent_view_.reset([[NSView alloc] initWithFrame:parent_frame]); | 
|   300     [parent_view_ setHidden:YES]; |   299     [parent_view_ setHidden:YES]; | 
|   301   } |   300   } | 
|   302  |   301  | 
|   303   void InstallAndToggleBar(BookmarkBarController* bar) { |   302   void InstallAndToggleBar(BookmarkBarController* bar) { | 
|   304     // Force loading of the nib. |   303     // Force loading of the nib. | 
|   305     [bar view]; |   304     [bar view]; | 
|   306     // Awkwardness to look like we've been installed. |   305     // Awkwardness to look like we've been installed. | 
| (...skipping 1817 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  2124                              "2f3b ] 4b "); |  2123                              "2f3b ] 4b "); | 
|  2125   actual = bookmarks::test::ModelStringFromNode(root); |  2124   actual = bookmarks::test::ModelStringFromNode(root); | 
|  2126   EXPECT_EQ(expected, actual); |  2125   EXPECT_EQ(expected, actual); | 
|  2127  |  2126  | 
|  2128   // Verify that the other bookmark folder can't be deleted. |  2127   // Verify that the other bookmark folder can't be deleted. | 
|  2129   BookmarkButton *otherButton = [bar_ otherBookmarksButton]; |  2128   BookmarkButton *otherButton = [bar_ otherBookmarksButton]; | 
|  2130   EXPECT_FALSE([bar_ canDragBookmarkButtonToTrash:otherButton]); |  2129   EXPECT_FALSE([bar_ canDragBookmarkButtonToTrash:otherButton]); | 
|  2131 } |  2130 } | 
|  2132  |  2131  | 
|  2133 }  // namespace |  2132 }  // namespace | 
| OLD | NEW |