Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(253)

Side by Side Diff: chrome/browser/ui/cocoa/panels/panel_cocoa_unittest.mm

Issue 24120005: Cleanup and IWYU-ify CocoaProfileTest and related tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: include order Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #include <Carbon/Carbon.h> 5 #include <Carbon/Carbon.h>
6 #import <Cocoa/Cocoa.h> 6 #import <Cocoa/Cocoa.h>
7 7
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/debug/debugger.h" 9 #include "base/debug/debugger.h"
10 #include "base/mac/scoped_nsautorelease_pool.h" 10 #include "base/mac/scoped_nsautorelease_pool.h"
11 #include "base/memory/scoped_ptr.h" 11 #include "base/memory/scoped_ptr.h"
12 #include "base/strings/sys_string_conversions.h" 12 #include "base/strings/sys_string_conversions.h"
13 #include "chrome/app/chrome_command_ids.h" // IDC_* 13 #include "chrome/app/chrome_command_ids.h" // IDC_*
14 #include "chrome/browser/chrome_notification_types.h" 14 #include "chrome/browser/chrome_notification_types.h"
15 #import "chrome/browser/ui/cocoa/browser_window_utils.h" 15 #import "chrome/browser/ui/cocoa/browser_window_utils.h"
16 #import "chrome/browser/ui/cocoa/cocoa_profile_test.h" 16 #import "chrome/browser/ui/cocoa/cocoa_profile_test.h"
17 #import "chrome/browser/ui/cocoa/panels/panel_cocoa.h" 17 #import "chrome/browser/ui/cocoa/panels/panel_cocoa.h"
18 #import "chrome/browser/ui/cocoa/panels/panel_titlebar_view_cocoa.h" 18 #import "chrome/browser/ui/cocoa/panels/panel_titlebar_view_cocoa.h"
19 #import "chrome/browser/ui/cocoa/panels/panel_window_controller_cocoa.h" 19 #import "chrome/browser/ui/cocoa/panels/panel_window_controller_cocoa.h"
20 #import "chrome/browser/ui/cocoa/run_loop_testing.h" 20 #import "chrome/browser/ui/cocoa/run_loop_testing.h"
21 #include "chrome/browser/ui/panels/panel.h" 21 #include "chrome/browser/ui/panels/panel.h"
22 #include "chrome/browser/ui/panels/panel_manager.h" 22 #include "chrome/browser/ui/panels/panel_manager.h"
23 #include "chrome/common/chrome_switches.h" 23 #include "chrome/common/chrome_switches.h"
24 #include "chrome/test/base/testing_profile.h"
24 #include "content/public/test/test_utils.h" 25 #include "content/public/test/test_utils.h"
25 #include "testing/gtest/include/gtest/gtest.h" 26 #include "testing/gtest/include/gtest/gtest.h"
26 #include "testing/gtest_mac.h" 27 #include "testing/gtest_mac.h"
27 28
28 class PanelAnimatedBoundsObserver : 29 class PanelAnimatedBoundsObserver :
29 public content::WindowedNotificationObserver { 30 public content::WindowedNotificationObserver {
30 public: 31 public:
31 PanelAnimatedBoundsObserver(Panel* panel) 32 PanelAnimatedBoundsObserver(Panel* panel)
32 : content::WindowedNotificationObserver( 33 : content::WindowedNotificationObserver(
33 chrome::NOTIFICATION_PANEL_BOUNDS_ANIMATIONS_FINISHED, 34 chrome::NOTIFICATION_PANEL_BOUNDS_ANIMATIONS_FINISHED,
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 NSWindow* frontmostWindow = [[NSApp orderedWindows] objectAtIndex:0]; 401 NSWindow* frontmostWindow = [[NSApp orderedWindows] objectAtIndex:0];
401 EXPECT_NSEQ(frontmostWindow, [native_window->controller_ window]); 402 EXPECT_NSEQ(frontmostWindow, [native_window->controller_ window]);
402 403
403 native_window2->ActivatePanel(); 404 native_window2->ActivatePanel();
404 frontmostWindow = [[NSApp orderedWindows] objectAtIndex:0]; 405 frontmostWindow = [[NSApp orderedWindows] objectAtIndex:0];
405 EXPECT_NSEQ(frontmostWindow, [native_window2->controller_ window]); 406 EXPECT_NSEQ(frontmostWindow, [native_window2->controller_ window]);
406 407
407 ClosePanelAndWait(panel); 408 ClosePanelAndWait(panel);
408 ClosePanelAndWait(panel2); 409 ClosePanelAndWait(panel2);
409 } 410 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698