[Bluetooth] decouple bluetoothTransfer and NfcHandoverManager's dependency

RESOLVED FIXED

Status

RESOLVED FIXED
4 years ago
4 years ago

People

(Reporter: gasolin, Assigned: gasolin)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Assignee)

Description

4 years ago
Currently bluetoothTransfer and NfcHandoverManager are reference to each other.
We could decouple it via event.

also need fix:
navigator.bluetooth should be readonly, so the current way to mockup bluetooth in NfcHandoverManager should be corrected.
Created attachment 8541581 [details] [review]
[PullReq] gasolin:issue-1115622 to mozilla-b2g:master
(Assignee)

Comment 2

4 years ago
Comment on attachment 8541581 [details] [review]
[PullReq] gasolin:issue-1115622 to mozilla-b2g:master

I use event to do the first step of decoupling.

we may need another file to really decouple the 2 way dependency between bt transfer and nfc handover.
Attachment #8541581 - Flags: feedback?(iliu)
Comment on attachment 8541581 [details] [review]
[PullReq] gasolin:issue-1115622 to mozilla-b2g:master

Fred, Beside of moving event to `handleEvent` in bluetooth_transfer.js, I'm okay for the change here. Thanks.
Attachment #8541581 - Flags: feedback?(iliu) → feedback+
Created attachment 8544385 [details] [review]
[PullReq] gasolin:issue-1115622-2 to mozilla-b2g:master
(Assignee)

Comment 5

4 years ago
Comment on attachment 8544385 [details] [review]
[PullReq] gasolin:issue-1115622-2 to mozilla-b2g:master

I removed handleEvent and test fine in real device. Ready for review
Attachment #8544385 - Flags: review?(iliu)
Comment on attachment 8544385 [details] [review]
[PullReq] gasolin:issue-1115622-2 to mozilla-b2g:master

Thanks for Fred's effort. r+ without nits.
Attachment #8544385 - Flags: review?(iliu) → review+
(Assignee)

Comment 7

4 years ago
add extra _ for private function names.

merged to master https://github.com/mozilla-b2g/gaia/commit/cd5c88c77debee57c87da79a3995bb34521fb14b
thanks!
Status: NEW → RESOLVED
Last Resolved: 4 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Autolander could not locate a review from a user within the suggested reviewer list. Either the patch author or the reviewer should be in the suggested reviewer list.

Note: Until bug 1095028 lands, the patch *must* have a review by a suggested reviewer. If you are the patch author, you can leave an additional R+ on the attachment for autolander to process it.

Updated

4 years ago
Keywords: checkin-needed
Autolander could not locate a review from a user within the suggested reviewer list. Either the patch author or the reviewer should be in the suggested reviewer list.

Note: Until bug 1095028 lands, the patch *must* have a review by a suggested reviewer. If you are the patch author, you can leave an additional R+ on the attachment for autolander to process it.
(Assignee)

Updated

4 years ago
Assignee: nobody → gasolin
(Assignee)

Updated

4 years ago
Blocks: 1093084
You need to log in before you can comment on or make changes to this bug.