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

Unified Diff: Source/modules/bluetooth/NavigatorBluetooth.h

Issue 639533002: bluetooth: Extend navigator.bluetooth IDL to include Bluetooth interface. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: GC Compile issue Created 6 years, 2 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
Index: Source/modules/bluetooth/NavigatorBluetooth.h
diff --git a/Source/modules/bluetooth/NavigatorBluetooth.h b/Source/modules/bluetooth/NavigatorBluetooth.h
index 7377f82299fc51bea1c65baf66cfc0df809cbd6d..be704c950a981880989e7c4fa956d29850f0f653 100644
--- a/Source/modules/bluetooth/NavigatorBluetooth.h
+++ b/Source/modules/bluetooth/NavigatorBluetooth.h
@@ -5,11 +5,32 @@
#ifndef NavigatorBluetooth_h
#define NavigatorBluetooth_h
+#include "platform/Supplementable.h"
+#include "platform/heap/Handle.h"
+
namespace blink {
-class NavigatorBluetooth {
+class Bluetooth;
+class Navigator;
+
+class NavigatorBluetooth FINAL
+ : public NoBaseWillBeGarbageCollected<NavigatorBluetooth>
+ , public WillBeHeapSupplement<Navigator> {
+ WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(NavigatorBluetooth);
+ DECLARE_EMPTY_VIRTUAL_DESTRUCTOR_WILL_BE_REMOVED(NavigatorBluetooth);
public:
- virtual ~NavigatorBluetooth() { }
+ static NavigatorBluetooth& from(Navigator&);
+
+ static Bluetooth* bluetooth(Navigator&);
+ Bluetooth* bluetooth() const;
+
+ void trace(Visitor*);
+
+private:
+ NavigatorBluetooth();
+ static const char* supplementName();
+
+ PersistentWillBeMember<Bluetooth> m_bluetooth;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698