mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-14 05:45:37 +00:00
Bug 1164498: Remove |DispatchBluetoothReply| from |BluetoothHfpManger|, r=btian
This patch replaces |DispatchBluetoothReply| in |BluetoothHfpManager| with corresponding calls to |DispatchReplySuccess| or |DispatchReplyError|.
This commit is contained in:
parent
0408a58958
commit
9001e89a61
@ -1916,12 +1916,7 @@ BluetoothHfpManager::OnScoConnectSuccess()
|
||||
{
|
||||
// For active connection request, we need to reply the DOMRequest
|
||||
if (mScoRunnable) {
|
||||
#ifdef MOZ_B2G_BT_API_V2
|
||||
DispatchReplySuccess(mScoRunnable);
|
||||
#else
|
||||
DispatchBluetoothReply(mScoRunnable,
|
||||
BluetoothValue(true), EmptyString());
|
||||
#endif
|
||||
mScoRunnable = nullptr;
|
||||
}
|
||||
|
||||
@ -1935,13 +1930,8 @@ void
|
||||
BluetoothHfpManager::OnScoConnectError()
|
||||
{
|
||||
if (mScoRunnable) {
|
||||
#ifdef MOZ_B2G_BT_API_V2
|
||||
DispatchReplyError(mScoRunnable,
|
||||
NS_LITERAL_STRING("Failed to create SCO socket!"));
|
||||
#else
|
||||
NS_NAMED_LITERAL_STRING(replyError, "Failed to create SCO socket!");
|
||||
DispatchBluetoothReply(mScoRunnable, BluetoothValue(), replyError);
|
||||
#endif
|
||||
mScoRunnable = nullptr;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user