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

Side by Side Diff: mojo/shell/background/background_shell.h

Issue 1675153002: ApplicationImpl->ShellConnection, mojom::Application->mojom::ShellClient (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ci2
Patch Set: . Created 4 years, 10 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 | « mojo/shell/application_package_apptest.cc ('k') | mojo/shell/background/background_shell.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 MOJO_SHELL_BACKGROUND_BACKGROUND_SHELL_H_ 5 #ifndef MOJO_SHELL_BACKGROUND_BACKGROUND_SHELL_H_
6 #define MOJO_SHELL_BACKGROUND_BACKGROUND_SHELL_H_ 6 #define MOJO_SHELL_BACKGROUND_BACKGROUND_SHELL_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "mojo/public/cpp/bindings/interface_request.h" 10 #include "mojo/public/cpp/bindings/interface_request.h"
11 #include "mojo/shell/public/interfaces/application.mojom.h" 11 #include "mojo/shell/public/interfaces/shell_client.mojom.h"
12 12
13 class GURL; 13 class GURL;
14 14
15 namespace mojo { 15 namespace mojo {
16 namespace shell { 16 namespace shell {
17 17
18 // BackgroundShell starts up the mojo shell on a background thread, and 18 // BackgroundShell starts up the mojo shell on a background thread, and
19 // destroys the thread in the destructor. Once created use CreateApplication() 19 // destroys the thread in the destructor. Once created use CreateApplication()
20 // to obtain an InterfaceRequest for the Application. The InterfaceRequest can 20 // to obtain an InterfaceRequest for the Application. The InterfaceRequest can
21 // then be bound to an ApplicationImpl. 21 // then be bound to an ApplicationImpl.
22 class BackgroundShell { 22 class BackgroundShell {
23 public: 23 public:
24 BackgroundShell(); 24 BackgroundShell();
25 ~BackgroundShell(); 25 ~BackgroundShell();
26 26
27 void Init(); 27 void Init();
28 28
29 // Obtains an InterfaceRequest for the specified url. 29 // Obtains an InterfaceRequest for the specified url.
30 InterfaceRequest<mojom::Application> CreateApplication(const GURL& url); 30 InterfaceRequest<mojom::ShellClient> CreateShellClientRequest(
31 const GURL& url);
31 32
32 private: 33 private:
33 class MojoThread; 34 class MojoThread;
34 35
35 scoped_ptr<MojoThread> thread_; 36 scoped_ptr<MojoThread> thread_;
36 37
37 DISALLOW_COPY_AND_ASSIGN(BackgroundShell); 38 DISALLOW_COPY_AND_ASSIGN(BackgroundShell);
38 }; 39 };
39 40
40 } // namespace shell 41 } // namespace shell
41 } // namespace mojo 42 } // namespace mojo
42 43
43 #endif // MOJO_SHELL_BACKGROUND_BACKGROUND_SHELL_H_ 44 #endif // MOJO_SHELL_BACKGROUND_BACKGROUND_SHELL_H_
OLDNEW
« no previous file with comments | « mojo/shell/application_package_apptest.cc ('k') | mojo/shell/background/background_shell.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698