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

Side by Side Diff: mojo/apps/js/application_delegate_impl.h

Issue 617503003: Mojo: MOJO_OVERRIDE -> override in mojo/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased Created 6 years, 2 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/application_manager/application_manager.cc ('k') | mojo/dbus/dbus_external_service.h » ('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 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_APPS_JS_CONTENT_HANDLER_H_ 5 #ifndef MOJO_APPS_JS_CONTENT_HANDLER_H_
6 #define MOJO_APPS_JS_CONTENT_HANDLER_H_ 6 #define MOJO_APPS_JS_CONTENT_HANDLER_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_vector.h" 9 #include "base/memory/scoped_vector.h"
10 #include "mojo/public/cpp/application/application_delegate.h" 10 #include "mojo/public/cpp/application/application_delegate.h"
(...skipping 10 matching lines...) Expand all
21 class JSApp; 21 class JSApp;
22 22
23 // Starts a new JSApp for each OnConnect call(). 23 // Starts a new JSApp for each OnConnect call().
24 24
25 class ContentHandlerImpl : public InterfaceImpl<ContentHandler> { 25 class ContentHandlerImpl : public InterfaceImpl<ContentHandler> {
26 public: 26 public:
27 ContentHandlerImpl(ApplicationDelegateImpl* content_handler); 27 ContentHandlerImpl(ApplicationDelegateImpl* content_handler);
28 virtual ~ContentHandlerImpl(); 28 virtual ~ContentHandlerImpl();
29 29
30 private: 30 private:
31 virtual void OnConnect(const mojo::String& url, 31 virtual void OnConnect(
32 URLResponsePtr content, 32 const mojo::String& url,
33 InterfaceRequest<ServiceProvider> service_provider) 33 URLResponsePtr content,
34 MOJO_OVERRIDE; 34 InterfaceRequest<ServiceProvider> service_provider) override;
35 35
36 ApplicationDelegateImpl* content_handler_; 36 ApplicationDelegateImpl* content_handler_;
37 }; 37 };
38 38
39 // Manages the JSApps started by this content handler. This class owns the one 39 // Manages the JSApps started by this content handler. This class owns the one
40 // reference to the Mojo shell. JSApps post a task to the content handler's 40 // reference to the Mojo shell. JSApps post a task to the content handler's
41 // thread to connect to a service or to quit.l 41 // thread to connect to a service or to quit.l
42 42
43 class ApplicationDelegateImpl : public ApplicationDelegate { 43 class ApplicationDelegateImpl : public ApplicationDelegate {
44 public: 44 public:
45 ApplicationDelegateImpl(); 45 ApplicationDelegateImpl();
46 virtual ~ApplicationDelegateImpl(); 46 virtual ~ApplicationDelegateImpl();
47 47
48 void StartJSApp(const std::string& url, URLResponsePtr content); 48 void StartJSApp(const std::string& url, URLResponsePtr content);
49 void QuitJSApp(JSApp* app); 49 void QuitJSApp(JSApp* app);
50 50
51 void ConnectToService(ScopedMessagePipeHandle pipe_handle, 51 void ConnectToService(ScopedMessagePipeHandle pipe_handle,
52 const std::string& application_url, 52 const std::string& application_url,
53 const std::string& interface_name); 53 const std::string& interface_name);
54 54
55 private: 55 private:
56 typedef ScopedVector<JSApp> AppVector; 56 typedef ScopedVector<JSApp> AppVector;
57 57
58 // ApplicationDelegate methods 58 // ApplicationDelegate methods
59 virtual void Initialize(ApplicationImpl* app) MOJO_OVERRIDE; 59 virtual void Initialize(ApplicationImpl* app) override;
60 virtual bool ConfigureIncomingConnection(ApplicationConnection* connection) 60 virtual bool ConfigureIncomingConnection(
61 MOJO_OVERRIDE; 61 ApplicationConnection* connection) override;
62 62
63 ApplicationImpl* application_impl_; 63 ApplicationImpl* application_impl_;
64 InterfaceFactoryImplWithContext<ContentHandlerImpl, ApplicationDelegateImpl> 64 InterfaceFactoryImplWithContext<ContentHandlerImpl, ApplicationDelegateImpl>
65 content_handler_factory_; 65 content_handler_factory_;
66 AppVector app_vector_; 66 AppVector app_vector_;
67 }; 67 };
68 68
69 } // namespace apps 69 } // namespace apps
70 } // namespace mojo 70 } // namespace mojo
71 71
72 #endif // MOJO_APPS_JS_CONTENT_HANDLER_H_ 72 #endif // MOJO_APPS_JS_CONTENT_HANDLER_H_
OLDNEW
« no previous file with comments | « mojo/application_manager/application_manager.cc ('k') | mojo/dbus/dbus_external_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698