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

Unified Diff: components/arc/bluetooth/arc_bluetooth_bridge.cc

Issue 2189183002: arc: bluetooth: Always acquire a NotifySession (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove IsNotifying since it's going to be private Created 4 years, 5 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/arc/bluetooth/arc_bluetooth_bridge.cc
diff --git a/components/arc/bluetooth/arc_bluetooth_bridge.cc b/components/arc/bluetooth/arc_bluetooth_bridge.cc
index 29b92d8ec94873772774a9f6a54966bd295babc2..fb716aca60ea93b031c0f2f2ad7cf2d99bb6217c 100644
--- a/components/arc/bluetooth/arc_bluetooth_bridge.cc
+++ b/components/arc/bluetooth/arc_bluetooth_bridge.cc
@@ -1099,11 +1099,6 @@ void ArcBluetoothBridge::RegisterForGattNotification(
return;
}
- if (characteristic->IsNotifying()) {
- callback.Run(mojom::BluetoothGattStatus::GATT_SUCCESS);
- return;
- }
-
characteristic->StartNotifySession(
base::Bind(&ArcBluetoothBridge::OnGattNotifyStartDone,
weak_factory_.GetWeakPtr(), callback,
@@ -1126,11 +1121,6 @@ void ArcBluetoothBridge::DeregisterForGattNotification(
return;
}
- if (!characteristic->IsNotifying()) {
- callback.Run(mojom::BluetoothGattStatus::GATT_SUCCESS);
- return;
- }
-
std::string char_id_str = characteristic->GetIdentifier();
std::unique_ptr<BluetoothGattNotifySession> notify =
std::move(notification_session_[char_id_str]);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698