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

Side by Side Diff: components/nacl/renderer/trusted_plugin_channel.h

Issue 1090233003: Set up a NaCl load status callback to start replacing "start_module". (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review Created 5 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 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 COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_ 5 #ifndef COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_
6 #define COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_ 6 #define COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "ipc/ipc_listener.h" 10 #include "ipc/ipc_listener.h"
(...skipping 10 matching lines...) Expand all
21 } // namespace IPC 21 } // namespace IPC
22 22
23 namespace nacl { 23 namespace nacl {
24 class NexeLoadManager; 24 class NexeLoadManager;
25 25
26 class TrustedPluginChannel : public IPC::Listener { 26 class TrustedPluginChannel : public IPC::Listener {
27 public: 27 public:
28 TrustedPluginChannel(NexeLoadManager* nexe_load_manager, 28 TrustedPluginChannel(NexeLoadManager* nexe_load_manager,
29 const IPC::ChannelHandle& handle, 29 const IPC::ChannelHandle& handle,
30 base::WaitableEvent* shutdown_event, 30 base::WaitableEvent* shutdown_event,
31 bool report_exit_status); 31 bool is_helper_nexe);
32 ~TrustedPluginChannel() override; 32 ~TrustedPluginChannel() override;
33 33
34 bool Send(IPC::Message* message); 34 bool Send(IPC::Message* message);
35 35
36 // Listener implementation. 36 // Listener implementation.
37 bool OnMessageReceived(const IPC::Message& message) override; 37 bool OnMessageReceived(const IPC::Message& message) override;
38 void OnChannelError() override; 38 void OnChannelError() override;
39 39
40 void OnReportExitStatus(int exit_status); 40 void OnReportExitStatus(int exit_status);
41 void OnReportLoadStatus(int load_status);
41 42
42 private: 43 private:
43 // Non-owning pointer. This is safe because the TrustedPluginChannel is owned 44 // Non-owning pointer. This is safe because the TrustedPluginChannel is owned
44 // by the NexeLoadManager pointed to here. 45 // by the NexeLoadManager pointed to here.
45 NexeLoadManager* nexe_load_manager_; 46 NexeLoadManager* nexe_load_manager_;
46 scoped_ptr<IPC::SyncChannel> channel_; 47 scoped_ptr<IPC::SyncChannel> channel_;
47 bool report_exit_status_; 48 bool is_helper_nexe_;
48 49
49 DISALLOW_COPY_AND_ASSIGN(TrustedPluginChannel); 50 DISALLOW_COPY_AND_ASSIGN(TrustedPluginChannel);
50 }; 51 };
51 52
52 } // namespace nacl 53 } // namespace nacl
53 54
54 #endif // COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_ 55 #endif // COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698