1page.title=Call Notifications
2@jd:body
3
4<!--
5    Copyright 2016 The Android Open Source Project
6
7    Licensed under the Apache License, Version 2.0 (the "License");
8    you may not use this file except in compliance with the License.
9    You may obtain a copy of the License at
10
11        http://www.apache.org/licenses/LICENSE-2.0
12
13    Unless required by applicable law or agreed to in writing, software
14    distributed under the License is distributed on an "AS IS" BASIS,
15    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16    See the License for the specific language governing permissions and
17    limitations under the License.
18-->
19<div id="qv-wrapper">
20  <div id="qv">
21    <h2>In this document</h2>
22    <ol id="auto-toc">
23    </ol>
24  </div>
25</div>
26
27<p>Android 7.0 moves functionality related to call notifications from the
28Telecom system service in the Android platform to the Dialer application.
29Previously, the responsibility for displaying call-related notifications was
30split between Telecom and the default Dialer app, creating inconsistencies in
31behavior. In Android 7.0, the Dialer assumes all responsibility for handling
32call notifications.</p>
33
34<h2 id=android_6>Behavior in Android 6.x and earlier</h2>
35<p>In earlier Android releases, Telecom and Dialer split responsibilities as
36described below:</p>
37
38<table>
39<tr>
40<th>Functionality</th>
41<th>Done by Telecom</th>
42<th>Done by Dialer</th>
43</tr>
44
45<tr>
46<td>Incoming call notification</td>
47<td>Yes (ringing, vibrate)</td>
48<td>Yes (notification display, caller ID)</td>
49</tr>
50
51<tr>
52<td>Send to voicemail</td>
53<td>Yes</td>
54<td>No</td>
55</tr>
56
57<tr>
58<td>Custom ringtone</td>
59<td>Yes</td>
60<td>No</td>
61</tr>
62
63<tr>
64<td>Missed call notifications</td>
65<td>Yes</td>
66<td>No</td>
67</tr>
68
69<tr>
70<td>Message Waiting Indicator (call voicemail)</td>
71<td>Yes (telephony)</td>
72<td>No</td>
73</tr>
74
75<tr>
76<td>Visual voicemail notifications</td>
77<td>No</td>
78<td>Yes</td>
79</tr>
80
81</tbody>
82</table>
83
84<p>Examples of inconsistent behavior caused by this responsibility split
85included:</p>
86<ul>
87<li>Telecom was responsible for starting the ringer/vibrator, but the dialer was
88responsible for displaying the incoming call notification. If the dialer is slow
89to startup, this can result in ringing starting several seconds before the
90incoming call notification is displayed.</li>
91<li>Telecom was responsible for displaying missed call notifications. As
92proprietary features (such as Google caller ID) do not work on these
93notifications, this could result in inconsistencies between Telecom
94notifications and Dialer UI (such as the call log).</li>
95</ul>
96
97<h2 id=android_7>Behavior in Android 7.0 and later</h2>
98<p>The Android Open Source Project (AOSP) Dialer implements the new
99functionality. For details, refer to the following documentation:</p>
100<ul>
101<li>Missed call notifications<br>
102<a href="https://android.googlesource.com/platform/packages/services/Telecomm/+/nougat-release/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java">Telecom/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java</a><br>
103<a href="https://android.googlesource.com/platform/packages/apps/Dialer/+/nougat-release/src/com/android/dialer/calllog/MissedCallNotificationReceiver.java">Dialer/src/com/android/dialer/calllog/MissedCallNotificationReceiver.java</a><br>
104<a href="https://android.googlesource.com/platform/packages/apps/Dialer/+/nougat-release/src/com/android/dialer/calllog/MissedCallNotifier.java">Dialer/src/com/android/dialer/calllog/MissedCallNotifier.java</a></li>
105<li>Playing ringtones:<br>
106<a href="https://android.googlesource.com/platform/frameworks/base/+/nougat-release/telecomm/java/android/telecom/InCallService.java">frameworks/base/telecomm/java/android/telecom/InCallService.java</a><br>
107<a href="https://android.googlesource.com/platform/packages/services/Telecomm/+/nougat-release/src/com/android/server/telecom/InCallController.java">Telecom/src/com/android/server/telecom/InCallController.java</a><br>
108<a href="https://android.googlesource.com/platform/packages/apps/Dialer/+/nougat-release/InCallUI/src/com/android/incallui/ringtone/">Dialer/InCallUI/src/com/android/incallui/ringtone</a><br>
109<a href="https://android.googlesource.com/platform/packages/apps/Dialer/+/nougat-release/InCallUI/src/com/android/incallui/StatusBarNotifier.java">Dialer/InCallUI/src/com/android/incallui/StatusBarNotifier.java</a></li>
110<li>VVM notifications<br>
111<a href="https://android.googlesource.com/platform/frameworks/base/+/nougat-release/telephony/java/android/telephony/TelephonyManager.java">frameworks/base/telephony/java/android/telephony/TelephonyManager.java</a><br>
112<a href="https://android.googlesource.com/platform/packages/services/Telephony/+/nougat-release/src/com/android/phone/PhoneInterfaceManager.java">Telephony/src/com/android/phone/PhoneInterfaceManager.java</a><br>
113<a href="https://android.googlesource.com/platform/packages/apps/Dialer/+/nougat-release/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java">Dialer/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java</a></li>
114</ul>
115
116<h2 id=implement>Implementation</h2>
117<p>Device implementers may need to update Telecom/Telephony components that
118expose APIs available for use by by the default Dialer.</p>
119