Skip to content

Commit

Permalink
fix voip for jflte
Browse files Browse the repository at this point in the history
referenced: https://gerrit.omnirom.org/#/c/8520/

orig. credit Steve Kondik <[email protected]>
modified for Omni by Jacob Whatley <[email protected]>

Change-Id: If710990d2a8af54872028eb06d9c1b5c6eadf0d0
  • Loading branch information
Jake Whatley committed Aug 22, 2014
1 parent 5e3a9a1 commit e09ed5b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
10 changes: 10 additions & 0 deletions legacy/alsa_sound/ALSADevice.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1905,6 +1905,16 @@ char* ALSADevice::getUCMDevice(uint32_t devices, int input, char *rxDevice)
if (!strncmp(mMicType, "analog", 6)) {
return strdup(SND_USE_CASE_DEV_HANDSET); /* HANDSET TX */
} else {
#ifdef SEPARATED_VOIP_SHORTCUT
if (mCallMode == AUDIO_MODE_IN_COMMUNICATION) {
if (!strncmp(rxDevice, SND_USE_CASE_DEV_VOIP_EARPIECE,
(strlen(SND_USE_CASE_DEV_VOIP_EARPIECE)+1))) {
return strdup(SND_USE_CASE_DEV_VOIP_HANDSET);
} else {
return strdup(SND_USE_CASE_DEV_VOIP_LINE);
}
}
#endif
if ((mDevSettingsFlag & DMIC_FLAG) && (mInChannels == 1)) {
#ifdef USES_FLUENCE_INCALL
if (mCallMode == AUDIO_MODE_IN_CALL
Expand Down
4 changes: 4 additions & 0 deletions legacy/alsa_sound/Android.mk
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,10 @@ ifeq ($(BOARD_USES_MOTOROLA_EMU_AUDIO),true)
common_cflags += -DMOTOROLA_EMU_AUDIO
endif

ifeq ($(SEPARATED_VOIP_SHORTCUT),true)
common_cflags += -DSEPARATED_VOIP_SHORTCUT
endif

include $(CLEAR_VARS)

LOCAL_ARM_MODE := arm
Expand Down

0 comments on commit e09ed5b

Please sign in to comment.