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

Side by Side Diff: ui/base/test/scoped_fake_nswindow_fullscreen.h

Issue 1868363002: Replace scoped_ptr with std::unique_ptr in //ui (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@scopedptrcc
Patch Set: scopedptrui: rebase-make_scoped_ptr 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 #ifndef UI_BASE_TEST_SCOPED_FAKE_NSWINDOW_FULLSCREEN_H_ 5 #ifndef UI_BASE_TEST_SCOPED_FAKE_NSWINDOW_FULLSCREEN_H_
6 #define UI_BASE_TEST_SCOPED_FAKE_NSWINDOW_FULLSCREEN_H_ 6 #define UI_BASE_TEST_SCOPED_FAKE_NSWINDOW_FULLSCREEN_H_
7 7
8 #include <memory>
9
8 #include "base/macros.h" 10 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h"
10 11
11 namespace ui { 12 namespace ui {
12 namespace test { 13 namespace test {
13 14
14 // Simulates fullscreen transitions on NSWindows. This allows testing fullscreen 15 // Simulates fullscreen transitions on NSWindows. This allows testing fullscreen
15 // logic without relying on the OS's fullscreen behavior as that tends to be 16 // logic without relying on the OS's fullscreen behavior as that tends to be
16 // flaky, even in interactive tests. We only allow one NSWindow per process to 17 // flaky, even in interactive tests. We only allow one NSWindow per process to
17 // be fullscreen at a time, which should be sufficient for tests. 18 // be fullscreen at a time, which should be sufficient for tests.
18 class ScopedFakeNSWindowFullscreen { 19 class ScopedFakeNSWindowFullscreen {
19 public: 20 public:
20 // Impl class to hide Obj-C implementation from this header. 21 // Impl class to hide Obj-C implementation from this header.
21 class Impl; 22 class Impl;
22 23
23 ScopedFakeNSWindowFullscreen(); 24 ScopedFakeNSWindowFullscreen();
24 ~ScopedFakeNSWindowFullscreen(); 25 ~ScopedFakeNSWindowFullscreen();
25 26
26 private: 27 private:
27 scoped_ptr<Impl> impl_; 28 std::unique_ptr<Impl> impl_;
28 29
29 DISALLOW_COPY_AND_ASSIGN(ScopedFakeNSWindowFullscreen); 30 DISALLOW_COPY_AND_ASSIGN(ScopedFakeNSWindowFullscreen);
30 }; 31 };
31 32
32 } // namespace test 33 } // namespace test
33 } // namespace ui 34 } // namespace ui
34 35
35 #endif // UI_BASE_TEST_SCOPED_FAKE_NSWINDOW_FULLSCREEN_H_ 36 #endif // UI_BASE_TEST_SCOPED_FAKE_NSWINDOW_FULLSCREEN_H_
OLDNEW
« no previous file with comments | « ui/base/test/scoped_fake_nswindow_focus.h ('k') | ui/base/test/scoped_preferred_scroller_style_mac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698