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

Side by Side Diff: device/serial/serial_connection.cc

Issue 380413003: Mojo: Use InterfaceFactory<Interface> for service registration (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix network_service_loader Created 6 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « device/serial/serial_connection.h ('k') | device/serial/serial_service_impl.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 #include "device/serial/serial_connection.h" 5 #include "device/serial/serial_connection.h"
6 6
7 #include "device/serial/serial_io_handler.h" 7 #include "device/serial/serial_io_handler.h"
8 8
9 namespace device { 9 namespace device {
10 10
(...skipping 24 matching lines...) Expand all
35 35
36 void SerialConnection::GetControlSignals( 36 void SerialConnection::GetControlSignals(
37 const mojo::Callback<void(serial::DeviceControlSignalsPtr)>& callback) { 37 const mojo::Callback<void(serial::DeviceControlSignalsPtr)>& callback) {
38 callback.Run(io_handler_->GetControlSignals()); 38 callback.Run(io_handler_->GetControlSignals());
39 } 39 }
40 40
41 void SerialConnection::Flush(const mojo::Callback<void(bool)>& callback) { 41 void SerialConnection::Flush(const mojo::Callback<void(bool)>& callback) {
42 callback.Run(io_handler_->Flush()); 42 callback.Run(io_handler_->Flush());
43 } 43 }
44 44
45 void SerialConnection::OnConnectionError() {
46 delete this;
47 }
48
49 } // namespace device 45 } // namespace device
OLDNEW
« no previous file with comments | « device/serial/serial_connection.h ('k') | device/serial/serial_service_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698