| 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/mac/scoped_nsobject.h" | 8 #include "base/mac/scoped_nsobject.h" |
| 9 #include "base/strings/string16.h" | 9 #include "base/strings/string16.h" |
| 10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| 11 #include "chrome/browser/bookmarks/bookmark_model_factory.h" | 11 #include "chrome/browser/bookmarks/bookmark_model_factory.h" |
| 12 #include "chrome/browser/signin/signin_manager.h" | 12 #include "chrome/browser/signin/signin_manager.h" |
| 13 #include "chrome/browser/signin/signin_manager_factory.h" | 13 #include "chrome/browser/signin/signin_manager_factory.h" |
| 14 #include "chrome/browser/ui/browser.h" | 14 #include "chrome/browser/ui/browser.h" |
| 15 #include "chrome/browser/ui/browser_window.h" | 15 #include "chrome/browser/ui/browser_window.h" |
| 16 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bubble_controller.h" | 16 #import "chrome/browser/ui/cocoa/bookmarks/bookmark_bubble_controller.h" |
| 17 #include "chrome/browser/ui/cocoa/browser_window_controller.h" | 17 #include "chrome/browser/ui/cocoa/browser_window_controller.h" |
| 18 #include "chrome/browser/ui/cocoa/cocoa_profile_test.h" | 18 #include "chrome/browser/ui/cocoa/cocoa_profile_test.h" |
| 19 #import "chrome/browser/ui/cocoa/info_bubble_window.h" | 19 #import "chrome/browser/ui/cocoa/info_bubble_window.h" |
| 20 #include "chrome/test/base/testing_profile.h" | 20 #include "chrome/test/base/testing_profile.h" |
| 21 #include "content/public/browser/notification_service.h" | 21 #include "content/public/browser/notification_service.h" |
| 22 #include "testing/gtest/include/gtest/gtest.h" | 22 #include "testing/gtest/include/gtest/gtest.h" |
| 23 #import "testing/gtest_mac.h" | 23 #import "testing/gtest_mac.h" |
| 24 #include "testing/platform_test.h" | 24 #include "testing/platform_test.h" |
| 25 | 25 |
| 26 using base::ASCIIToUTF16; |
| 26 using content::WebContents; | 27 using content::WebContents; |
| 27 | 28 |
| 28 // Watch for bookmark pulse notifications so we can confirm they were sent. | 29 // Watch for bookmark pulse notifications so we can confirm they were sent. |
| 29 @interface BookmarkPulseObserver : NSObject { | 30 @interface BookmarkPulseObserver : NSObject { |
| 30 int notifications_; | 31 int notifications_; |
| 31 } | 32 } |
| 32 @property (assign, nonatomic) int notifications; | 33 @property (assign, nonatomic) int notifications; |
| 33 @end | 34 @end |
| 34 | 35 |
| 35 | 36 |
| (...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 471 // Normally this would be sent up the responder tree correctly, but since | 472 // Normally this would be sent up the responder tree correctly, but since |
| 472 // tests run in the background, key window and main window are never set on | 473 // tests run in the background, key window and main window are never set on |
| 473 // NSApplication. Adding it to NSApplication directly removes the need for | 474 // NSApplication. Adding it to NSApplication directly removes the need for |
| 474 // worrying about what the current window with focus is. | 475 // worrying about what the current window with focus is. |
| 475 - (void)editBookmarkNode:(id)sender { | 476 - (void)editBookmarkNode:(id)sender { |
| 476 EXPECT_TRUE([sender respondsToSelector:@selector(node)]); | 477 EXPECT_TRUE([sender respondsToSelector:@selector(node)]); |
| 477 BookmarkBubbleControllerTest::edits_++; | 478 BookmarkBubbleControllerTest::edits_++; |
| 478 } | 479 } |
| 479 | 480 |
| 480 @end | 481 @end |
| OLD | NEW |