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

Unified Diff: content/browser/bluetooth/web_bluetooth_service_impl.h

Issue 1898303003: bluetooth: Clean up WebBluetoothServiceImpl when adapter is removed (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@my-origin
Patch Set: Re-enable tests Created 4 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
Index: content/browser/bluetooth/web_bluetooth_service_impl.h
diff --git a/content/browser/bluetooth/web_bluetooth_service_impl.h b/content/browser/bluetooth/web_bluetooth_service_impl.h
index c8a8d81afcc9ac70806c4cb6b68417e487174151..e044254563de5e54bc8724e16b1bc001b42aa96e 100644
--- a/content/browser/bluetooth/web_bluetooth_service_impl.h
+++ b/content/browser/bluetooth/web_bluetooth_service_impl.h
@@ -60,6 +60,8 @@ class WebBluetoothServiceImpl : public blink::mojom::WebBluetoothService,
void DidFinishNavigation(NavigationHandle* navigation_handle) override;
// BluetoothAdapter::Observer:
+ void AdapterPresentChanged(device::BluetoothAdapter* adapter,
+ bool present) override;
void GattCharacteristicValueChanged(
device::BluetoothAdapter* adapter,
device::BluetoothGattCharacteristic* characteristic,
@@ -123,8 +125,8 @@ class WebBluetoothServiceImpl : public blink::mojom::WebBluetoothService,
void CrashRendererAndClosePipe(bad_message::BadMessageReason reason);
url::Origin GetOrigin();
- // All state (maps, sets, etc.) should be cleaned after navigations
- // that are not in the same page.
+ // Clears all state (maps, sets, etc).
+ void ClearState();
// Map to keep track of the characteristics' notify sessions.
std::unordered_map<std::string,
« no previous file with comments | « content/browser/bluetooth/bluetooth_dispatcher_host.cc ('k') | content/browser/bluetooth/web_bluetooth_service_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698