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

Side by Side Diff: services/js/js_app_shell.h

Issue 780213002: Put code in //services/js in namespace js (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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 2014 The Chromium Authors. All rights reserved. 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 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_SERVICES_JS_JS_APP_SHELL_H_ 5 #ifndef SERVICES_JS_JS_APP_SHELL_H_
6 #define MOJO_SERVICES_JS_JS_APP_SHELL_H_ 6 #define SERVICES_JS_JS_APP_SHELL_H_
7 7
8 #include "gin/handle.h" 8 #include "gin/handle.h"
9 #include "gin/wrappable.h" 9 #include "gin/wrappable.h"
10 #include "mojo/edk/js/handle.h" 10 #include "mojo/edk/js/handle.h"
11 11
12 namespace mojo {
13 namespace js { 12 namespace js {
14 13
15 class JSApp; 14 class JSApp;
16 15
17 class JSAppShell : public gin::Wrappable<JSAppShell> { 16 class JSAppShell : public gin::Wrappable<JSAppShell> {
18 public: 17 public:
19 static gin::WrapperInfo kWrapperInfo; 18 static gin::WrapperInfo kWrapperInfo;
20 static gin::Handle<JSAppShell> Create(v8::Isolate* isolate, JSApp* js_app); 19 static gin::Handle<JSAppShell> Create(v8::Isolate* isolate, JSApp* js_app);
21 20
22 private: 21 private:
23 explicit JSAppShell(JSApp* js_app); 22 explicit JSAppShell(JSApp* js_app);
24 ~JSAppShell() override; 23 ~JSAppShell() override;
25 24
26 // gin::WrappableBase 25 // gin::WrappableBase
27 gin::ObjectTemplateBuilder GetObjectTemplateBuilder(v8::Isolate* isolate) 26 gin::ObjectTemplateBuilder GetObjectTemplateBuilder(v8::Isolate* isolate)
28 override; 27 override;
29 28
30 // Bound to JS method "connectToApplication". 29 // Bound to JS method "connectToApplication".
31 void ConnectToApplication(const std::string& application_url, 30 void ConnectToApplication(const std::string& application_url,
32 v8::Handle<v8::Value> service_provider); 31 v8::Handle<v8::Value> service_provider);
33 32
34 JSApp* js_app_; 33 JSApp* js_app_;
35 34
36 DISALLOW_COPY_AND_ASSIGN(JSAppShell); 35 DISALLOW_COPY_AND_ASSIGN(JSAppShell);
37 }; 36 };
38 37
39 } // namespace js 38 } // namespace js
40 } // namespace mojo
41 39
42 #endif // MOJO_SERVICES_JS_JS_APP_SHELL_H_ 40 #endif // SERVICES_JS_JS_APP_SHELL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698