|
1 /* -*- Mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; tab-width: 40 -*- */ |
|
2 /* vim: set ts=2 et sw=2 tw=40: */ |
|
3 /* This Source Code Form is subject to the terms of the Mozilla Public |
|
4 * License, v. 2.0. If a copy of the MPL was not distributed with this file, |
|
5 * You can obtain one at http://mozilla.org/MPL/2.0/. */ |
|
6 |
|
7 #include "nsISupports.idl" |
|
8 |
|
9 [scriptable, uuid(efd352af-9eee-48dc-8e92-4d4fdbc89ecb)] |
|
10 interface nsIDOMMozVoicemailStatus : nsISupports |
|
11 { |
|
12 readonly attribute unsigned long serviceId; |
|
13 |
|
14 /** |
|
15 * Whether or not there are messages waiting in the voicemail box |
|
16 */ |
|
17 readonly attribute boolean hasMessages; |
|
18 |
|
19 /** |
|
20 * The total message count. Some voicemail indicators will only specify that |
|
21 * messages are waiting, but not the actual number. In that case, the value |
|
22 * of messageCount will be -1, indicating the unknown message count. |
|
23 * |
|
24 * Logic for a voicemail notification might look something like: |
|
25 * if (status.hasMessages) { |
|
26 * // show new voicemail notification |
|
27 * if (status.messageCount > 0) { |
|
28 * // add a label for the message count |
|
29 * } |
|
30 * } else { |
|
31 * // hide the voicemail notification |
|
32 * } |
|
33 */ |
|
34 readonly attribute long messageCount; |
|
35 |
|
36 /** |
|
37 * Return call number received for this voicemail status, or null if one |
|
38 * wasn't provided. |
|
39 */ |
|
40 readonly attribute DOMString returnNumber; |
|
41 |
|
42 /** |
|
43 * Displayable return call message received for this voicemail status, or null |
|
44 * if one wasn't provided. |
|
45 */ |
|
46 readonly attribute DOMString returnMessage; |
|
47 }; |