Closed Bug 792345 Opened 12 years ago Closed 12 years ago

[b2g-bluetooth] Handle call status change

Categories

(Core :: DOM: Device Interfaces, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla18
blocking-basecamp +

People

(Reporter: echou, Assigned: echou)

References

Details

(Whiteboard: [LOE:S])

Attachments

(2 files, 5 obsolete files)

In order to notify HS of call status change, we need to implement an listener to observe call status change.
Assignee: nobody → echou
Blocks: 788300
blocking-basecamp: --- → ?
Whiteboard: [LOE:S]
Implementation of call status observer. Please note that "StartListening()" hasn't been called yet.
Attachment #662476 - Flags: review?(kyle)
blocking-basecamp: ? → +
Comment on attachment 662476 [details] [diff] [review] patch 1: v1: Basic functions for observing call status Review of attachment 662476 [details] [diff] [review]: ----------------------------------------------------------------- We should probably add checks for MOZ_B2G_RIL around the additions to the makefile, and at any place we might need to access the RIL. Idea looks decent though, only reason the r- is there is because MOZ_B2G_BT doesn't necessarily assume MOZ_B2G_RIL. ::: dom/bluetooth/BluetoothRilListener.cpp @@ +62,5 @@ > + > +bool > +BluetoothRilListener::StartListening() > +{ > + nsCOMPtr<nsIRILContentHelper> ril = do_GetService(NS_RILCONTENTHELPER_CONTRACTID); You should check for service validity here.
Attachment #662476 - Flags: review?(kyle) → review-
Added MOZ_B2G_RIL check to Makefile & checked service availability.
Attachment #662476 - Attachment is obsolete: true
Attachment #662801 - Flags: review?(kyle)
Followed spec to implement CallStateChanged function. Created a runnable for sending RING indicator every 3 seconds.
Attachment #662801 - Attachment is obsolete: true
Attachment #662801 - Flags: review?(kyle)
Attachment #662804 - Flags: review?(kyle)
Added MOZ_B2G_RIL check to Makefile & checked service availability.
Attachment #662805 - Flags: review?(kyle)
Comment on attachment 662804 [details] [diff] [review] patch 2: v1: implement CallStateChanged Review of attachment 662804 [details] [diff] [review]: ----------------------------------------------------------------- ::: dom/bluetooth/BluetoothHfpManager.cpp @@ +206,5 @@ > SendSocketData(new mozilla::ipc::SocketRawData(msg.get())); > } > > +/* > + * CallStateChanged will be called whenever call status is changed, and it Nit: space at end of line
Attachment #662804 - Flags: review?(kyle) → review+
Comment on attachment 662805 [details] [diff] [review] patch 1: v2: Basic functions for observing call status Review of attachment 662805 [details] [diff] [review]: ----------------------------------------------------------------- ::: dom/bluetooth/BluetoothRilListener.cpp @@ +64,5 @@ > +BluetoothRilListener::StartListening() > +{ > + nsCOMPtr<nsIRILContentHelper> ril = do_GetService(NS_RILCONTENTHELPER_CONTRACTID); > + if (!ril) { > + NS_ERROR("No RIL Service!"); Nit: space at end of line @@ +77,5 @@ > +bool > +BluetoothRilListener::StopListening() > +{ > + nsCOMPtr<nsIRILContentHelper> ril = do_GetService(NS_RILCONTENTHELPER_CONTRACTID); > + if (!ril) { Nit: indentation @@ +78,5 @@ > +BluetoothRilListener::StopListening() > +{ > + nsCOMPtr<nsIRILContentHelper> ril = do_GetService(NS_RILCONTENTHELPER_CONTRACTID); > + if (!ril) { > + NS_ERROR("No RIL Service!"); Nit: space at end of line ::: dom/bluetooth/Makefile.in @@ +40,5 @@ > $(NULL) > > +ifdef MOZ_B2G_RIL > +CPPSRCS += BluetoothRilListener.cpp \ > + $(NULL) Nit: Don't need the \ $(NULL)
Attachment #662805 - Flags: review?(kyle) → review+
Nit picked.
Attachment #662804 - Attachment is obsolete: true
NS_WARNING can only be passed one parameter.
Attachment #664875 - Attachment is obsolete: true
Status: NEW → RESOLVED
Closed: 12 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
Target Milestone: --- → mozilla18
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: