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

Side by Side Diff: ui/base/test/scoped_fake_nswindow_fullscreen_unittest.mm

Issue 1849343003: mac: Remove IsOSSnowLeopard(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 8 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "ui/base/test/scoped_fake_nswindow_fullscreen.h" 5 #import "ui/base/test/scoped_fake_nswindow_fullscreen.h"
6 6
7 #import "base/mac/mac_util.h" 7 #import "base/mac/mac_util.h"
8 #import "base/mac/scoped_nsobject.h" 8 #import "base/mac/scoped_nsobject.h"
9 #import "base/mac/sdk_forward_declarations.h" 9 #import "base/mac/sdk_forward_declarations.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 23 matching lines...) Expand all
34 return targetSize_; 34 return targetSize_;
35 } 35 }
36 36
37 @end 37 @end
38 38
39 namespace ui { 39 namespace ui {
40 namespace test { 40 namespace test {
41 41
42 // Test the order of notifications sent when faking fullscreen transitions. 42 // Test the order of notifications sent when faking fullscreen transitions.
43 TEST(ScopedFakeNSWindowFullscreenTest, TestOrdering) { 43 TEST(ScopedFakeNSWindowFullscreenTest, TestOrdering) {
44 if (base::mac::IsOSSnowLeopard())
45 return;
46
47 base::MessageLoopForUI message_loop; 44 base::MessageLoopForUI message_loop;
48 45
49 NSUInteger style_mask = NSTexturedBackgroundWindowMask | NSTitledWindowMask | 46 NSUInteger style_mask = NSTexturedBackgroundWindowMask | NSTitledWindowMask |
50 NSClosableWindowMask | NSMiniaturizableWindowMask | 47 NSClosableWindowMask | NSMiniaturizableWindowMask |
51 NSResizableWindowMask; 48 NSResizableWindowMask;
52 base::scoped_nsobject<NSWindow> window( 49 base::scoped_nsobject<NSWindow> window(
53 [[NSWindow alloc] initWithContentRect:NSMakeRect(50, 60, 130, 170) 50 [[NSWindow alloc] initWithContentRect:NSMakeRect(50, 60, 130, 170)
54 styleMask:style_mask 51 styleMask:style_mask
55 backing:NSBackingStoreBuffered 52 backing:NSBackingStoreBuffered
56 defer:NO]); 53 defer:NO]);
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 [window toggleFullScreen:nil]; 128 [window toggleFullScreen:nil];
132 [window setFrame:new_frame display:YES animate:NO]; 129 [window setFrame:new_frame display:YES animate:NO];
133 EXPECT_TRUE([did_exit waitForCount:2]); 130 EXPECT_TRUE([did_exit waitForCount:2]);
134 EXPECT_NSEQ(frame_outside_fullscreen, [window frame]); 131 EXPECT_NSEQ(frame_outside_fullscreen, [window frame]);
135 132
136 [window close]; 133 [window close];
137 } 134 }
138 135
139 } // namespace test 136 } // namespace test
140 } // namespace ui 137 } // namespace ui
OLDNEW
« no previous file with comments | « ui/base/test/scoped_fake_nswindow_fullscreen.mm ('k') | ui/views/cocoa/bridged_native_widget.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698