[cleanup] Remove unused |isConnected| from bluetooth2

RESOLVED FIXED in Firefox 42

Status

defect
RESOLVED FIXED
4 years ago
4 years ago

People

(Reporter: tzimmermann, Assigned: ben.tian)

Tracking

unspecified
FxOS-S4 (07Aug)
ARM
Gonk (Firefox OS)
Dependency tree / graph

Firefox Tracking Flags

(firefox42 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

|BluetoothServiceBluedroid::IsConnected| is newer in Bluetooth v1. Bluetooth v2 should adopt this code.

::: dom/bluetooth/bluedroid/BluetoothServiceBluedroid.h
@@ +161,5 @@
>    virtual bool
>    IsConnected(uint16_t aProfileId);
> +#else
> +  virtual void
> +  IsConnected(const uint16_t aServiceUuid,

See also bug 929376 and bug 1172914.
Assignee

Comment 1

4 years ago
Assignee: nobody → btian
Attachment #8643508 - Flags: review?(joliu)
Attachment #8643508 - Flags: feedback?(jaliu)
Assignee

Comment 2

4 years ago
Comment on attachment 8643508 [details] [diff] [review]
Patch 1 (v1): Port bug 929376 to bluetooth2

Jamin and I decide not to add this method per offline discussion with Fred. The reason is that System app maintains its own list of connected profiles and doesn't call adapter.isConnected() at all. If there's specific API requirement, gecko can add/redesign API to query whether a profile is connected in the future.

I'll still upload a patch to remove |isConnected| in bluetooth2.
Attachment #8643508 - Attachment is obsolete: true
Attachment #8643508 - Flags: review?(joliu)
Attachment #8643508 - Flags: feedback?(jaliu)
Assignee

Updated

4 years ago
Summary: Use Bluetooth v1 variant for |BluetoothServiceBluedroid::IsConnected| → [cleanup] Remove unused |isConnected| from bluetooth2
Comment on attachment 8643524 [details] [diff] [review]
Patch 2 (v1): Remove unused |isConnected| method from bluetooth2

Review of attachment 8643524 [details] [diff] [review]:
-----------------------------------------------------------------

I'm not sure if it makes sense that the System app maintains the list of connected profiles. But since |IsConnected| is unimplemented anyway, we can also remove it.

I also encourage you to completely remove v1 in the near future. :)
Attachment #8643524 - Flags: review?(tzimmermann) → review+
Assignee

Comment 5

4 years ago
(In reply to Thomas Zimmermann [:tzimmermann] [:tdz] from comment #4)
> I also encourage you to completely remove v1 in the near future. :)

We sure will. v1 is still there since we're working on feature phone features (2.2-based) on m-c branch. v1 can be removed once we move to work on the 2.2-based branch.
It will be nice to have `isConnected` method when we have more than one adapter, so we can remove the connected profiles list and relay the request to the concrete connection status.

In Gaia we also maintain v1 API in master as well, 
please ping me when you plan to remove v1 API, so we can align the plan.
https://hg.mozilla.org/mozilla-central/rev/f9cac61e1235
Status: NEW → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → FxOS-S4 (07Aug)
You need to log in before you can comment on or make changes to this bug.