Created
December 6, 2016 19:22
-
-
Save invisiblek/4ba54d49125c3a4885d516b074c10c4c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/com/android/server/telecom/Ringer.java b/src/com/android/server/telecom/Ringer.java | |
index f53f212..3ce3c16 100644 | |
--- a/src/com/android/server/telecom/Ringer.java | |
+++ b/src/com/android/server/telecom/Ringer.java | |
@@ -117,12 +117,13 @@ public class Ringer { | |
stopCallWaiting(); | |
- boolean[] shouldRingOrVibrate = | |
- shouldRingOrVibrateForContact(foregroundCall.getContactUri()); | |
- boolean ringAllowed = shouldRingOrVibrate[0]; | |
- boolean vibrationAllowed = shouldRingOrVibrate[1]; | |
+ /* | |
+ if (!shouldRingForContact(foregroundCall.getContactUri())) { | |
+ return false; | |
+ } | |
+ */ | |
- if (ringAllowed && isRingerAudible) { | |
+ if (isRingerAudible) { | |
mRingingCall = foregroundCall; | |
Log.event(foregroundCall, Log.Events.START_RINGER); | |
@@ -146,7 +147,8 @@ public class Ringer { | |
Log.i(this, "startRingingOrCallWaiting, skipping because volume is 0"); | |
} | |
- if (vibrationAllowed && shouldVibrate(mContext) && !mIsVibrating) { | |
+ //if (vibrationAllowed && shouldVibrate(mContext) && !mIsVibrating) { | |
+ if (shouldVibrate(mContext) && !mIsVibrating) { | |
mVibrator.vibrate(VIBRATION_PATTERN, VIBRATION_PATTERN_REPEAT, | |
VIBRATION_ATTRIBUTES); | |
mIsVibrating = true; | |
diff --git a/src/com/android/server/telecom/callfiltering/DirectToVoicemailCallFilter.java b/src/com/android/server/telecom/callfiltering/DirectToVoicemailCallFilter.java | |
index 4e11827..ea64eb3 100644 | |
--- a/src/com/android/server/telecom/callfiltering/DirectToVoicemailCallFilter.java | |
+++ b/src/com/android/server/telecom/callfiltering/DirectToVoicemailCallFilter.java | |
@@ -42,7 +42,7 @@ public class DirectToVoicemailCallFilter implements IncomingCallFilter.CallFilte | |
@Override | |
public void onCallerInfoQueryComplete(Uri handle, CallerInfo info) { | |
CallFilteringResult result; | |
- if ((handle != null) && Objects.equals(callHandle, handle)) { | |
+ if (Objects.equals(callHandle, handle)) { | |
if (info != null && info.shouldSendToVoicemail) { | |
result = new CallFilteringResult( | |
false, // shouldAllowCall |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment