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

Side by Side Diff: headless/lib/browser/headless_browser_main_parts.h

Issue 1854043002: convert //headless to std::unique_ptr (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 #ifndef HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_MAIN_PARTS_H_ 5 #ifndef HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_MAIN_PARTS_H_
6 #define HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_MAIN_PARTS_H_ 6 #define HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_MAIN_PARTS_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include <memory>
9
9 #include "content/public/browser/browser_main_parts.h" 10 #include "content/public/browser/browser_main_parts.h"
10 #include "headless/public/headless_browser.h" 11 #include "headless/public/headless_browser.h"
11 12
12 namespace devtools_http_handler { 13 namespace devtools_http_handler {
13 class DevToolsHttpHandler; 14 class DevToolsHttpHandler;
14 } 15 }
15 16
16 namespace headless { 17 namespace headless {
17 18
18 class HeadlessBrowserContext; 19 class HeadlessBrowserContext;
19 class HeadlessBrowserImpl; 20 class HeadlessBrowserImpl;
20 21
21 class HeadlessBrowserMainParts : public content::BrowserMainParts { 22 class HeadlessBrowserMainParts : public content::BrowserMainParts {
22 public: 23 public:
23 explicit HeadlessBrowserMainParts(HeadlessBrowserImpl* browser); 24 explicit HeadlessBrowserMainParts(HeadlessBrowserImpl* browser);
24 ~HeadlessBrowserMainParts() override; 25 ~HeadlessBrowserMainParts() override;
25 26
26 // content::BrowserMainParts implementation: 27 // content::BrowserMainParts implementation:
27 void PreMainMessageLoopRun() override; 28 void PreMainMessageLoopRun() override;
28 void PostMainMessageLoopRun() override; 29 void PostMainMessageLoopRun() override;
29 30
30 HeadlessBrowserContext* browser_context() const; 31 HeadlessBrowserContext* browser_context() const;
31 32
32 private: 33 private:
33 HeadlessBrowserImpl* browser_; // Not owned. 34 HeadlessBrowserImpl* browser_; // Not owned.
34 scoped_ptr<HeadlessBrowserContext> browser_context_; 35 std::unique_ptr<HeadlessBrowserContext> browser_context_;
35 scoped_ptr<devtools_http_handler::DevToolsHttpHandler> devtools_http_handler_; 36 std::unique_ptr<devtools_http_handler::DevToolsHttpHandler>
37 devtools_http_handler_;
36 38
37 DISALLOW_COPY_AND_ASSIGN(HeadlessBrowserMainParts); 39 DISALLOW_COPY_AND_ASSIGN(HeadlessBrowserMainParts);
38 }; 40 };
39 41
40 } // namespace headless 42 } // namespace headless
41 43
42 #endif // HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_MAIN_PARTS_H_ 44 #endif // HEADLESS_LIB_BROWSER_HEADLESS_BROWSER_MAIN_PARTS_H_
OLDNEW
« no previous file with comments | « headless/lib/browser/headless_browser_impl.cc ('k') | headless/lib/browser/headless_content_browser_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698