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

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

Issue 288903003: [Bluetooth] Standardize Bluetooth device address format to XX:XX:XX:XX:XX:XX. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 7 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
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_win.h" 5 #include "device/bluetooth/bluetooth_device_win.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 21 matching lines...) Expand all
32 scoped_refptr<base::SequencedTaskRunner> ui_task_runner, 32 scoped_refptr<base::SequencedTaskRunner> ui_task_runner,
33 scoped_refptr<BluetoothSocketThread> socket_thread, 33 scoped_refptr<BluetoothSocketThread> socket_thread,
34 net::NetLog* net_log, 34 net::NetLog* net_log,
35 const net::NetLog::Source& net_log_source) 35 const net::NetLog::Source& net_log_source)
36 : BluetoothDevice(), 36 : BluetoothDevice(),
37 ui_task_runner_(ui_task_runner), 37 ui_task_runner_(ui_task_runner),
38 socket_thread_(socket_thread), 38 socket_thread_(socket_thread),
39 net_log_(net_log), 39 net_log_(net_log),
40 net_log_source_(net_log_source) { 40 net_log_source_(net_log_source) {
41 name_ = state.name; 41 name_ = state.name;
42 address_ = state.address; 42 address_ = CanonicalizeAddress(state.address);
43 bluetooth_class_ = state.bluetooth_class; 43 bluetooth_class_ = state.bluetooth_class;
44 visible_ = state.visible; 44 visible_ = state.visible;
45 connected_ = state.connected; 45 connected_ = state.connected;
46 paired_ = state.authenticated; 46 paired_ = state.authenticated;
47 47
48 for (ScopedVector<BluetoothTaskManagerWin::ServiceRecordState>::const_iterator 48 for (ScopedVector<BluetoothTaskManagerWin::ServiceRecordState>::const_iterator
49 iter = state.service_record_states.begin(); 49 iter = state.service_record_states.begin();
50 iter != state.service_record_states.end(); 50 iter != state.service_record_states.end();
51 ++iter) { 51 ++iter) {
52 uint8 sdp_bytes_buffer[kSdpBytesBufferSize]; 52 uint8 sdp_bytes_buffer[kSdpBytesBufferSize];
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 for (ServiceRecordList::const_iterator iter = service_record_list_.begin(); 245 for (ServiceRecordList::const_iterator iter = service_record_list_.begin();
246 iter != service_record_list_.end(); 246 iter != service_record_list_.end();
247 ++iter) { 247 ++iter) {
248 if ((*iter)->uuid() == uuid) 248 if ((*iter)->uuid() == uuid)
249 return *iter; 249 return *iter;
250 } 250 }
251 return NULL; 251 return NULL;
252 } 252 }
253 253
254 } // namespace device 254 } // namespace device
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698