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

Unified Diff: Source/modules/bluetooth/Bluetooth.cpp

Issue 1066933008: bluetooth: Refactor Bluetooth and Stub out BluetoothInteraction. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@bluetooth-uuids-fix-casing-2
Patch Set: Created 5 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/modules/bluetooth/Bluetooth.h ('k') | Source/modules/bluetooth/Bluetooth.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/bluetooth/Bluetooth.cpp
diff --git a/Source/modules/bluetooth/Bluetooth.cpp b/Source/modules/bluetooth/Bluetooth.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..f84de6fe157d646109ef36f223d3097b666f0b95
--- /dev/null
+++ b/Source/modules/bluetooth/Bluetooth.cpp
@@ -0,0 +1,24 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "config.h"
+#include "modules/bluetooth/Bluetooth.h"
+
+#include "bindings/core/v8/ScriptPromise.h"
+
+namespace blink {
+
+ScriptPromise Bluetooth::requestDevice(ScriptState* s)
+{
+ return bluetoothDiscovery()->requestDevice(s);
+}
+
+BluetoothDiscovery* Bluetooth::bluetoothDiscovery()
+{
+ if (!m_bluetoothDiscovery)
+ m_bluetoothDiscovery = new BluetoothDiscovery;
+ return m_bluetoothDiscovery.get();
+}
+
+}; // blink
« no previous file with comments | « Source/modules/bluetooth/Bluetooth.h ('k') | Source/modules/bluetooth/Bluetooth.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698