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

Side by Side Diff: third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.cpp

Issue 2614523002: Shorten some method names in //third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.h (Closed)
Patch Set: shorten some method names in //third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.h Created 3 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
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 "modules/bluetooth/BluetoothDevice.h" 5 #include "modules/bluetooth/BluetoothDevice.h"
6 6
7 #include "bindings/core/v8/CallbackPromiseAdapter.h" 7 #include "bindings/core/v8/CallbackPromiseAdapter.h"
8 #include "bindings/core/v8/ScriptPromise.h" 8 #include "bindings/core/v8/ScriptPromise.h"
9 #include "bindings/core/v8/ScriptPromiseResolver.h" 9 #include "bindings/core/v8/ScriptPromiseResolver.h"
10 #include "core/dom/DOMException.h" 10 #include "core/dom/DOMException.h"
(...skipping 28 matching lines...) Expand all
39 } 39 }
40 40
41 // static 41 // static
42 mojom::blink::WebBluetoothDeviceIdPtr BluetoothDevice::createMojoDeviceId( 42 mojom::blink::WebBluetoothDeviceIdPtr BluetoothDevice::createMojoDeviceId(
43 const String& deviceId) { 43 const String& deviceId) {
44 auto result = mojom::blink::WebBluetoothDeviceId::New(); 44 auto result = mojom::blink::WebBluetoothDeviceId::New();
45 result->device_id = deviceId; 45 result->device_id = deviceId;
46 return result; 46 return result;
47 } 47 }
48 48
49 BluetoothRemoteGATTService* 49 BluetoothRemoteGATTService* BluetoothDevice::getOrCreateRemoteGATTService(
50 BluetoothDevice::getOrCreateBluetoothRemoteGATTService(
51 const String& serviceInstanceId, 50 const String& serviceInstanceId,
52 const String& uuid, 51 const String& uuid,
53 bool isPrimary, 52 bool isPrimary,
54 const String& deviceInstanceId) { 53 const String& deviceInstanceId) {
55 return m_attributeInstanceMap->getOrCreateBluetoothRemoteGATTService( 54 return m_attributeInstanceMap->getOrCreateRemoteGATTService(
56 serviceInstanceId, uuid, isPrimary, deviceInstanceId); 55 serviceInstanceId, uuid, isPrimary, deviceInstanceId);
57 } 56 }
58 57
59 bool BluetoothDevice::isValidService(const String& serviceInstanceId) { 58 bool BluetoothDevice::isValidService(const String& serviceInstanceId) {
60 return m_attributeInstanceMap->containsService(serviceInstanceId); 59 return m_attributeInstanceMap->containsService(serviceInstanceId);
61 } 60 }
62 61
63 BluetoothRemoteGATTCharacteristic* 62 BluetoothRemoteGATTCharacteristic*
64 BluetoothDevice::getOrCreateBluetoothRemoteGATTCharacteristic( 63 BluetoothDevice::getOrCreateRemoteGATTCharacteristic(
65 ExecutionContext* context, 64 ExecutionContext* context,
66 const String& characteristicInstanceId, 65 const String& characteristicInstanceId,
67 const String& serviceInstanceId, 66 const String& serviceInstanceId,
68 const String& uuid, 67 const String& uuid,
69 uint32_t characteristicProperties, 68 uint32_t characteristicProperties,
70 BluetoothRemoteGATTService* service) { 69 BluetoothRemoteGATTService* service) {
71 return m_attributeInstanceMap->getOrCreateBluetoothRemoteGATTCharacteristic( 70 return m_attributeInstanceMap->getOrCreateRemoteGATTCharacteristic(
72 context, characteristicInstanceId, serviceInstanceId, uuid, 71 context, characteristicInstanceId, serviceInstanceId, uuid,
73 characteristicProperties, service); 72 characteristicProperties, service);
74 } 73 }
75 74
76 bool BluetoothDevice::isValidCharacteristic( 75 bool BluetoothDevice::isValidCharacteristic(
77 const String& characteristicInstanceId) { 76 const String& characteristicInstanceId) {
78 return m_attributeInstanceMap->containsCharacteristic( 77 return m_attributeInstanceMap->containsCharacteristic(
79 characteristicInstanceId); 78 characteristicInstanceId);
80 } 79 }
81 80
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 123
125 DEFINE_TRACE(BluetoothDevice) { 124 DEFINE_TRACE(BluetoothDevice) {
126 EventTargetWithInlineData::trace(visitor); 125 EventTargetWithInlineData::trace(visitor);
127 ContextLifecycleObserver::trace(visitor); 126 ContextLifecycleObserver::trace(visitor);
128 visitor->trace(m_attributeInstanceMap); 127 visitor->trace(m_attributeInstanceMap);
129 visitor->trace(m_gatt); 128 visitor->trace(m_gatt);
130 visitor->trace(m_bluetooth); 129 visitor->trace(m_bluetooth);
131 } 130 }
132 131
133 } // namespace blink 132 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698