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

Side by Side Diff: device/bluetooth/bluetooth_device_chromeos.cc

Issue 11884027: Separated BluetoothServiceRecord interface from BluetoothServiceRecordChromeOs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: style fix Created 7 years, 11 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 | « no previous file | device/bluetooth/bluetooth_service_record.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/bluetooth/bluetooth_device_chromeos.h" 5 #include "device/bluetooth/bluetooth_device_chromeos.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 10 matching lines...) Expand all
21 #include "chromeos/dbus/bluetooth_device_client.h" 21 #include "chromeos/dbus/bluetooth_device_client.h"
22 #include "chromeos/dbus/bluetooth_input_client.h" 22 #include "chromeos/dbus/bluetooth_input_client.h"
23 #include "chromeos/dbus/bluetooth_out_of_band_client.h" 23 #include "chromeos/dbus/bluetooth_out_of_band_client.h"
24 #include "chromeos/dbus/dbus_thread_manager.h" 24 #include "chromeos/dbus/dbus_thread_manager.h"
25 #include "chromeos/dbus/introspectable_client.h" 25 #include "chromeos/dbus/introspectable_client.h"
26 #include "dbus/bus.h" 26 #include "dbus/bus.h"
27 #include "dbus/object_path.h" 27 #include "dbus/object_path.h"
28 #include "device/bluetooth/bluetooth_adapter_chromeos.h" 28 #include "device/bluetooth/bluetooth_adapter_chromeos.h"
29 #include "device/bluetooth/bluetooth_out_of_band_pairing_data.h" 29 #include "device/bluetooth/bluetooth_out_of_band_pairing_data.h"
30 #include "device/bluetooth/bluetooth_service_record.h" 30 #include "device/bluetooth/bluetooth_service_record.h"
31 #include "device/bluetooth/bluetooth_service_record_chromeos.h"
31 #include "device/bluetooth/bluetooth_socket_chromeos.h" 32 #include "device/bluetooth/bluetooth_socket_chromeos.h"
32 #include "device/bluetooth/bluetooth_utils.h" 33 #include "device/bluetooth/bluetooth_utils.h"
33 #include "third_party/cros_system_api/dbus/service_constants.h" 34 #include "third_party/cros_system_api/dbus/service_constants.h"
34 35
35 using device::BluetoothDevice; 36 using device::BluetoothDevice;
36 using device::BluetoothOutOfBandPairingData; 37 using device::BluetoothOutOfBandPairingData;
37 using device::BluetoothServiceRecord; 38 using device::BluetoothServiceRecord;
38 using device::BluetoothSocket; 39 using device::BluetoothSocket;
39 40
40 namespace chromeos { 41 namespace chromeos {
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
397 bool success) { 398 bool success) {
398 if (!success) { 399 if (!success) {
399 error_callback.Run(); 400 error_callback.Run();
400 return; 401 return;
401 } 402 }
402 403
403 ScopedVector<BluetoothServiceRecord> records; 404 ScopedVector<BluetoothServiceRecord> records;
404 for (BluetoothDeviceClient::ServiceMap::const_iterator i = 405 for (BluetoothDeviceClient::ServiceMap::const_iterator i =
405 service_map.begin(); i != service_map.end(); ++i) { 406 service_map.begin(); i != service_map.end(); ++i) {
406 records.push_back( 407 records.push_back(
407 new BluetoothServiceRecord(address(), i->second)); 408 new BluetoothServiceRecordChromeOs(address(), i->second));
miket_OOO 2013/01/15 18:40:19 FYI: $ grep -oR ChromeOS * | wc -l 1124 $ grep -o
keybuk 2013/01/15 19:42:00 I agree, let's name this ChromeOS and fix the othe
youngki 2013/01/16 00:39:38 Done.
408 } 409 }
409 callback.Run(records); 410 callback.Run(records);
410 } 411 }
411 412
412 void BluetoothDeviceChromeOs::OnSetTrusted(const base::Closure& callback, 413 void BluetoothDeviceChromeOs::OnSetTrusted(const base::Closure& callback,
413 const ErrorCallback& error_callback, 414 const ErrorCallback& error_callback,
414 bool success) { 415 bool success) {
415 if (success) { 416 if (success) {
416 callback.Run(); 417 callback.Run();
417 } else { 418 } else {
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
719 } 720 }
720 721
721 722
722 // static 723 // static
723 BluetoothDeviceChromeOs* BluetoothDeviceChromeOs::Create( 724 BluetoothDeviceChromeOs* BluetoothDeviceChromeOs::Create(
724 BluetoothAdapterChromeOs* adapter) { 725 BluetoothAdapterChromeOs* adapter) {
725 return new BluetoothDeviceChromeOs(adapter); 726 return new BluetoothDeviceChromeOs(adapter);
726 } 727 }
727 728
728 } // namespace chromeos 729 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | device/bluetooth/bluetooth_service_record.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698