Pin Chrome's shortcut to the Win10 Start menu on install and OS upgrade.
[chromium-blink-merge.git] / chromecast / browser / cast_browser_main_parts.h
blob4b5b5d8dfb9bdcfcba6cd59d9ba23ab10ffcaab9
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
3 // found in the LICENSE file.
5 #ifndef CHROMECAST_BROWSER_CAST_BROWSER_MAIN_PARTS_H_
6 #define CHROMECAST_BROWSER_CAST_BROWSER_MAIN_PARTS_H_
8 #include "base/macros.h"
9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h"
11 #include "content/public/browser/browser_main_parts.h"
12 #include "content/public/common/main_function_params.h"
14 namespace media {
15 class AudioManagerFactory;
18 namespace net {
19 class NetLog;
22 namespace chromecast {
23 namespace shell {
24 class CastBrowserProcess;
25 class URLRequestContextFactory;
27 class CastBrowserMainParts : public content::BrowserMainParts {
28 public:
29 // This class does not take ownership of |url_request_content_factory|.
30 CastBrowserMainParts(
31 const content::MainFunctionParams& parameters,
32 URLRequestContextFactory* url_request_context_factory,
33 scoped_ptr<::media::AudioManagerFactory> audio_manager_factory);
34 ~CastBrowserMainParts() override;
36 // content::BrowserMainParts implementation:
37 void PreMainMessageLoopStart() override;
38 void PostMainMessageLoopStart() override;
39 int PreCreateThreads() override;
40 void PreMainMessageLoopRun() override;
41 bool MainMessageLoopRun(int* result_code) override;
42 void PostMainMessageLoopRun() override;
44 private:
45 scoped_ptr<CastBrowserProcess> cast_browser_process_;
46 const content::MainFunctionParams parameters_; // For running browser tests.
47 URLRequestContextFactory* const url_request_context_factory_;
48 scoped_ptr<::media::AudioManagerFactory> audio_manager_factory_;
49 scoped_ptr<net::NetLog> net_log_;
51 DISALLOW_COPY_AND_ASSIGN(CastBrowserMainParts);
54 } // namespace shell
55 } // namespace chromecast
57 #endif // CHROMECAST_BROWSER_CAST_BROWSER_MAIN_PARTS_H_