| Index: remoting/protocol/host_event_dispatcher.cc
|
| diff --git a/remoting/protocol/host_event_dispatcher.cc b/remoting/protocol/host_event_dispatcher.cc
|
| index 3257b930126b574eb9ced0cf6932ef8ce424e200..411ea0727d31b28512a35cb6f0f3824af95e2f3d 100644
|
| --- a/remoting/protocol/host_event_dispatcher.cc
|
| +++ b/remoting/protocol/host_event_dispatcher.cc
|
| @@ -16,19 +16,17 @@ namespace protocol {
|
|
|
| HostEventDispatcher::HostEventDispatcher()
|
| : ChannelDispatcherBase(kEventChannelName),
|
| - input_stub_(nullptr) {
|
| + input_stub_(nullptr),
|
| + parser_(base::Bind(&HostEventDispatcher::OnMessageReceived,
|
| + base::Unretained(this)),
|
| + reader()) {
|
| }
|
|
|
| HostEventDispatcher::~HostEventDispatcher() {
|
| }
|
|
|
| -void HostEventDispatcher::OnInitialized() {
|
| - reader_.Init(channel(), base::Bind(
|
| - &HostEventDispatcher::OnMessageReceived, base::Unretained(this)));
|
| -}
|
| -
|
| -void HostEventDispatcher::OnMessageReceived(
|
| - scoped_ptr<EventMessage> message, const base::Closure& done_task) {
|
| +void HostEventDispatcher::OnMessageReceived(scoped_ptr<EventMessage> message,
|
| + const base::Closure& done_task) {
|
| DCHECK(input_stub_);
|
|
|
| base::ScopedClosureRunner done_runner(done_task);
|
|
|