Bug 1159267: Share Bluedroid's A2DP manager between Bluetooth v1 and v2, r=btian

Bluedroid's A2DP manager is the same for Bluetooth v1 and v2, except
fixes for bug 1062697 and bug 1148311 in v1. This patch merges both
variants. The last remaining difference is a call to |DistributeSignal|,
which differs between both implementations.
This commit is contained in:
Thomas Zimmermann 2015-05-06 09:58:04 +02:00
parent 80366e6970
commit a9b8c25faa

View File

@ -298,11 +298,7 @@ BluetoothA2dpManager::ResetAvrcp()
mMediaNumber = 0;
mTotalMediaCount = 0;
mPosition = 0;
#ifdef MOZ_B2G_BT_API_V2
mPlayStatus = ControlPlayStatus::PLAYSTATUS_UNKNOWN;
#else
mPlayStatus = ControlPlayStatus::PLAYSTATUS_STOPPED;
#endif
}
/*
@ -933,9 +929,6 @@ BluetoothA2dpManager::UpdateRegisterNotification(BluetoothAvrcpEvent aEvent,
}
mPlaybackInterval = aParam;
break;
#ifdef MOZ_B2G_BT_API_V2
// Missing in bluetooth2
#else
case AVRCP_EVENT_APP_SETTINGS_CHANGED:
mAppSettingsChangedNotifyType = AVRCP_NTF_INTERIM;
param.mNumAttr = 2;
@ -944,7 +937,6 @@ BluetoothA2dpManager::UpdateRegisterNotification(BluetoothAvrcpEvent aEvent,
param.mIds[1] = AVRCP_PLAYER_ATTRIBUTE_SHUFFLE;
param.mValues[1] = AVRCP_PLAYER_VAL_OFF_SHUFFLE;
break;
#endif
default:
break;
}