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

Side by Side Diff: ui/gfx/test/ui_cocoa_test_helper.h

Issue 2247493003: [Mac] Clean up SadTabView and let SadTabController provide its content (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use base::mac::ObjCCast Created 4 years, 4 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
« no previous file with comments | « chrome/browser/ui/cocoa/tab_contents/sad_tab_view_cocoa.mm ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef UI_GFX_TEST_UI_COCOA_TEST_HELPER_H_ 5 #ifndef UI_GFX_TEST_UI_COCOA_TEST_HELPER_H_
6 #define UI_GFX_TEST_UI_COCOA_TEST_HELPER_H_ 6 #define UI_GFX_TEST_UI_COCOA_TEST_HELPER_H_
7 7
8 #include <set> 8 #include <set>
9 9
10 #import <Cocoa/Cocoa.h> 10 #import <Cocoa/Cocoa.h>
11 11
12 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
13 #import "base/mac/scoped_nsautorelease_pool.h" 13 #import "base/mac/scoped_nsautorelease_pool.h"
14 #import "base/mac/scoped_nsobject.h"
14 #include "testing/platform_test.h" 15 #include "testing/platform_test.h"
15 16
16 // Background windows normally will not display things such as focus 17 // Background windows normally will not display things such as focus
17 // rings. This class allows -isKeyWindow to be manipulated to test 18 // rings. This class allows -isKeyWindow to be manipulated to test
18 // such things. 19 // such things.
19 @interface CocoaTestHelperWindow : NSWindow { 20 @interface CocoaTestHelperWindow : NSWindow {
20 @private 21 @private
21 BOOL pretendIsKeyWindow_; 22 BOOL pretendIsKeyWindow_;
22 BOOL useDefaultConstraints_; 23 BOOL useDefaultConstraints_;
23 } 24 }
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 #define EXPECT_NSRECT_EQ(expected, actual) \ 146 #define EXPECT_NSRECT_EQ(expected, actual) \
146 EXPECT_TRUE(CGFLOAT_EQ(expected.origin.x, actual.origin.x) && \ 147 EXPECT_TRUE(CGFLOAT_EQ(expected.origin.x, actual.origin.x) && \
147 CGFLOAT_EQ(expected.origin.y, actual.origin.y) && \ 148 CGFLOAT_EQ(expected.origin.y, actual.origin.y) && \
148 CGFLOAT_EQ(expected.size.width, actual.size.width) && \ 149 CGFLOAT_EQ(expected.size.width, actual.size.width) && \
149 CGFLOAT_EQ(expected.size.height, actual.size.height)) << \ 150 CGFLOAT_EQ(expected.size.height, actual.size.height)) << \
150 "Rects do not match: " << \ 151 "Rects do not match: " << \
151 [NSStringFromRect(expected) UTF8String] << \ 152 [NSStringFromRect(expected) UTF8String] << \
152 " != " << [NSStringFromRect(actual) UTF8String] 153 " != " << [NSStringFromRect(actual) UTF8String]
153 154
154 #endif // UI_GFX_TEST_UI_COCOA_TEST_HELPER_H_ 155 #endif // UI_GFX_TEST_UI_COCOA_TEST_HELPER_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/tab_contents/sad_tab_view_cocoa.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698