251 Commits

Author SHA1 Message Date
Yorke Lee
f1a349bda3 Add default dialer checks to Telecom/Telephony
Check for the default dialer or the modify phone state permission
for various TelecomManager/TelephonyManager methods.

Make sure to check the user-selected default rather than the
hardcoded package name.

Exercise this code in TestDialerActivity.

Bug: 20304458
Change-Id: Ic04cd8f2ba98e1d54c39549ae89d3e11cd5cdafb
2015-04-29 16:21:00 -07:00
Yorke Lee
b7018ba660 Merge "Simplify DefaultDialerManager" into mnc-dev 2015-04-28 18:57:46 +00:00
Yorke Lee
8e0207ba5b Simplify DefaultDialerManager
The previous code worked with ComponentNames because it was
based off existing code for the default SMS application.
We only really need the package name however, so simplify the
code by storing and retrieving the package name directly.

Bug: 20304458
Change-Id: Icabd3a9f0f8166c105360494b601160d13767fad
2015-04-28 11:30:47 -07:00
Yorke Lee
d0922ed723 Merge "Rename setDefaultDialerApplication for consistency" into mnc-dev 2015-04-27 22:49:34 +00:00
Yorke Lee
a162f02f76 Rename setDefaultDialerApplication for consistency
Change-Id: I8227df913bdb0ed5e1b3472f9d4ebea1158b366b
2015-04-27 15:17:50 -07:00
Yorke Lee
610438230b Add utility method isDefaultOrSystemDialer
Will be used by various system components to determine if a
given package name is a privileged Dialer

Bug: 20333102
Bug: 20304411
Change-Id: I1e5bcbde8ee9a5dc6936b118b1b78f32d97737a6
2015-04-27 12:55:23 -07:00
Etan Cohen
f2570cb595 Merge "Doc fix - incorrect format (included argument) for function reference." 2015-04-25 01:44:27 +00:00
Etan Cohen
912270e22d Doc fix - incorrect format (included argument) for function reference.
Change-Id: I2cdf7b4f078b1ab0556fcc3fad5287f86641c396
2015-04-24 18:43:41 -07:00
Etan Cohen
4e4fec1b8d Merge "Fix documentation - non-public API." 2015-04-25 01:08:11 +00:00
Etan Cohen
237a59767d Fix documentation - non-public API.
Change-Id: I418bf47b197936b2f50b231425312d5b6d272df8
2015-04-24 18:06:59 -07:00
Etan Cohen
cd895cdf4d Merge changes from topic 'mwd-merge-042415'
* changes:
  Rename removeVideoCallListener to unregisterCallback
  Bluetooth document fix: remove reference from open API to hidden entities
  Fix build due to merge of 7595842 and renaming due to 8eb87f0
  Merge commit '052a0da' into merge2
  Merge commit 'db1dbb8' into merge2
  Merge commit '7e5e791' into merge2
  Merge commit '170102d' into merge2
  Merge commit '4cb5d80' into merge2
  Merge commit '83cda00' into merge2
  Merge commit 'c91bc62' into merge2
  Merge commit 'cffc360' into merge2
  Merge commit '7f61051' into merge2
  Merge commit '167c3a7' into merge2
  Merge commit '4467b98' into merge2
  Merge commit '25a217c' into merge2
  Merge commit '04b18ec' into merge2
  Merge commit '7595842' into merge2
  Merge commit '2bbd2b6' into merge2
  Merge commit '4890351' into merge2
  Merge commit 'cd405fe' into merge2
  Merge commit '6ddbb5e' into merge2
  Merge commit 'de93575' into merge2
  Merge commit '9561e74' into merge2
2015-04-25 00:51:47 +00:00
Yorke Lee
eca706ed9d Merge "Add APIs to getDefaultDialerPackage and getSystemDialerPackage" 2015-04-24 23:11:42 +00:00
Etan Cohen
1418054108 Rename removeVideoCallListener to unregisterCallback
Change-Id: Ie6b5ac9131e81900efc7d3fa67056aa47d566a44
2015-04-24 15:22:03 -07:00
Etan Cohen
8942724930 Fix build due to merge of 7595842 and renaming due to 8eb87f0
I.e. rename mVideoCallback -> mCallback. Line with original name
was added in mwd, renaming was done in master. The renaming CL
was cherry-picked to mwd (and build probably fixed there).

Change-Id: I462a0fedd00293a148404e1419740bf492ae5de9
2015-04-24 14:06:40 -07:00
Etan Cohen
94f2c27aca Merge commit '7f61051' into merge2 2015-04-24 14:02:07 -07:00
Etan Cohen
f491a5844a Merge commit '04b18ec' into merge2 2015-04-24 13:56:58 -07:00
Etan Cohen
d7b4b81274 Merge commit '7595842' into merge2
Change-Id: I7e11e98e6d59562374195a8761d64a79dc0268e8
2015-04-24 13:56:35 -07:00
Santos Cordon
c1ec931f00 Fix up DisconnectCause description.
Change-Id: Ib2b52b6f8bc8fe945df3684f4e1ed9e04f78b061
2015-04-24 11:37:07 -07:00
Yorke Lee
1011f4870c Add APIs to getDefaultDialerPackage and getSystemDialerPackage
getDefaultDialerPackage is a public API and will be used by
apps to determine if they are the default dialer.

getSystemDialerPackage is a hidden API and is only used by
system components.

Also add new public string constants to allow apps to show
a dialog requesting that the user change the current default
dialer.

Bug: 20304458
Change-Id: I121d36741474c1fe171c372fb766a6c128228c9c
2015-04-24 11:12:34 -07:00
Santos Cordon
1ff1d3203f Merge "Remove CallState and rename PRE_DIAL_WAIT" 2015-04-24 00:06:55 +00:00
Yorke Lee
2973868885 Merge "Add TelecomManager.placeCall" 2015-04-23 23:49:24 +00:00
Yorke Lee
3e56ba14cc Add TelecomManager.placeCall
Places a new outgoing call using the system telecom service
with the specified parameters.

Making emergency calls using this method requires that the
method-caller is either the user-selected default dialer app
or preloaded system dialer app.

Requires that the caller have the
{@link android.Manifest.permission#CALL_PHONE} permission.

Bug: 20348183
Change-Id: Ieedb5628e8c6be25137944e7c3639dc1d9bc61df
2015-04-23 16:48:52 -07:00
Santos Cordon
e3c507b79b Remove CallState and rename PRE_DIAL_WAIT
Bug: 20532827
Bug: 20532435
Change-Id: I5f0308c5cf4e4a9cf9020b4fe7fa5f3f8dee6e67
2015-04-23 14:44:19 -07:00
Yorke Lee
6446d97942 Merge "Add hidden class in framework for managing the default dialer settings" 2015-04-23 17:23:41 +00:00
Yorke Lee
014de02dd2 Add hidden class in framework for managing the default dialer settings
Bug: 20303635
Change-Id: I7e7318086ade9531fb85f08b8e3f1f001ee0a8d9
2015-04-23 10:19:52 -07:00
Yorke Lee
e661d9fb6f Make CAPABILITY_CAN_PAUSE_VIDEO public
Change-Id: If20f642a3d6bda886a68bb1e0ce459c38361a73c
2015-04-21 13:42:24 -07:00
Tyler Gunn
4cf116ff20 Merge "API Cleanup - rename IConferenceable to Conferenceable." 2015-04-20 20:12:47 +00:00
Tyler Gunn
df2cbc8989 API Cleanup - rename IConferenceable to Conferenceable.
Bug: 20165255
Change-Id: If4cb323749b6ef9e8657506434d760d07c34167f
2015-04-20 09:13:01 -07:00
Svet Ganov
d3c1ddb892 Merge "Add OP_READ_PHONE_STATE app op - framework" 2015-04-17 21:34:04 +00:00
Svet Ganov
16a1689950 Add OP_READ_PHONE_STATE app op - framework
The READ_PHONE_STATE permission protects PII information and
is in the Phone group. This change is adding the corrseponding
app op for gating access to the API guarded by READ_POHNE state
which will be used instead as an access control for legacy apps.

Change-Id: I2ff895a5a0e529f26ec0ad706266a30d829268ba
2015-04-17 20:43:56 +00:00
Andrew Lee
84a264004d Remove deprecated VideoCallListener methods.
These shouldn't be needed because the video call APIs were never
previously made public.

Bug: 20160491
Change-Id: Ic9c5d0d1e8618bfe61f8905d4afaeaa37f51c915
2015-04-16 17:07:12 -07:00
Andrew Lee
600aaf013a Merge "Fix comment typos. =(" 2015-04-16 23:46:57 +00:00
Santos Cordon
223a80d7c6 Merge "Unfinal getPhone." 2015-04-16 23:42:01 +00:00
Santos Cordon
29886d8571 Unfinal getPhone.
The change to make it final was breaking existing apps.

...and other changes.

Bug: 20283873
Change-Id: I8db4243850ad15f688dbca59ff5427b4799cbd1b
2015-04-16 16:12:20 -07:00
Jay Shrauner
d01242946e Merge "Remove connection substate" 2015-04-16 23:06:05 +00:00
Andrew Lee
7c9ee2b0c5 Fix comment typos. =(
Bug:20160491
Change-Id: I1782f6a0c5597f937c8882c6c94740c63cd63b53
2015-04-16 15:26:08 -07:00
Andrew Lee
843b327ae2 Merge "Rename Call*Listener to Call*Callback." 2015-04-16 22:18:39 +00:00
Andrew Lee
da80c870a8 Rename Call*Listener to Call*Callback.
Deprecate the existing Listener methods and interfaces so that they
can be replaced.

Bug: 20160491
Change-Id: I11c104c625b03751f3792fc4367883c18c6e2d54
2015-04-16 15:17:20 -07:00
Jay Shrauner
8f98843924 Remove connection substate
Bug:20300433
Change-Id: Ifefc08b5165de3e0b6ce92007e5f612879dcc4d9
2015-04-16 14:42:39 -07:00
Andrew Lee
3e3e2f2b9c Fix missing comma.
Change-Id: Ied739e7f1b6d548237821db553f27994b0ee92af
2015-04-16 13:49:30 -07:00
Andrew Lee
0f51da328d resolve merge conflicts of edc625f to m-wireless-dev.
Change-Id: Ibbcd764505ccc38f9f61c96993d979a099f1cc6b
2015-04-16 13:11:55 -07:00
Yorke Lee
167c3a717f DO NOT MERGE Change hasVoicemailNumber to getVoicemailNumber
Bug: 20223485
Change-Id: I293572bb6c32c5084fe684e7cfe7bd2bbfb5443b
2015-04-16 12:40:23 -07:00
Santos Cordon
0d4e216665 Merge "Move Phone.java APIs into InCallService" 2015-04-16 17:58:16 +00:00
Santos Cordon
a2492810df Move Phone.java APIs into InCallService
This change is one step in the right direction of getting rid of
Phone.java.

Phone.java was deemed superfluous and this change moves the methods
previously exposed in Phone.java into InCallService.  This was done by
having InCallService listen to Phone and pipe the calls as appropriate.
However, state still lives in Phone and we eventually want to move that
code into InCallService.  That will be done in a later CL.

Bug: 20160495
Change-Id: Id142431c253c1f24f260da42e8bedd1eb2ce448b
2015-04-16 10:54:12 -07:00
Yorke Lee
a22a09666b Merge "Change hasVoicemailNumber to getVoicemailNumber" 2015-04-16 17:05:19 +00:00
Tyler Gunn
04b18ec153 Merge "Fix incorrect Conference time for IMS conference calls." into m-wireless-dev 2015-04-16 16:38:23 +00:00
Tyler Gunn
75958420f2 Support for multiple VideoCall.Listeners for a VideoCall.
The current code assumes that only a single instance of VideoCall will be
provided to the default system InCall UI.  Ideally multiple
InCallService implementations should be able to use the VideoCall APIs.
Note: it only really makes sense for a single InCallService to get/set
the video surfaces.

- Fixed bug in ParcelableCall which would cause a new instance of
VideoCallImpl to be created every time a call is updated from Telecom.
Added a flag to ParcelableCall to indicate whether the parcel includes a
change to the video provider information, which is used when unparceling
to determine whether to set/create the video call impl.
- Renamed "setVideoCallback" to "addVideocallback".
- Modified Connection.VideoProvider code to keep a list of Video callbacks
and fire off all of them when Video Provider changes occur.

Bug: 20092420
Change-Id: Ic16b6afe1b7532cc64d006c133adbae57946d97d
2015-04-16 16:37:25 +00:00
Yorke Lee
49e2d46812 Change hasVoicemailNumber to getVoicemailNumber
Bug: 20223485

Change-Id: I67eb12e2030ec8f73326ade4eb750b0c2f6e52ad
2015-04-16 09:30:57 -07:00
Tyler Gunn
bd1f9ece87 Fix incorrect Conference time for IMS conference calls.
Looks like the connectTimeMillis parameter to ParcelableConference
got removed when partner CLs were merged in.  Adding it back fixes
the problem.

Bug: 20159830
Change-Id: Ibe067f64f8faea6fd1eb157e5073bc702978c511
2015-04-16 08:38:10 -07:00
Jay Shrauner
e14bbcc0e2 DO NOT MERGE Hide getUserSelectedOutgoingPhoneAccount
Bug:20224972
Change-Id: I21528788e38817f77fc68b56e26a33ac726d39e2
2015-04-15 20:49:15 -07:00