Commit Graph

6943 Commits

Author SHA1 Message Date
Dongwon Kang
d87e7c98a6 Fix a typo in javadoc. am: e1b0d4a253
am: 52c8542213

Change-Id: Iea37a6b4d5428a0342ff36a549cdddfb0a6bf89d
2018-08-23 18:16:10 -07:00
Dongwon Kang
52c8542213 Fix a typo in javadoc.
am: e1b0d4a253

Change-Id: I65e6b8b5110b4175c35e8bcdef5299418de623ca
2018-08-23 18:03:50 -07:00
Dongwon Kang
e1b0d4a253 Fix a typo in javadoc.
Test: javadoc fix.
Bug: 112882126
Change-Id: I69f55aaa49103690a796ff394fcd1934891a52f2
2018-08-23 21:14:23 +00:00
TreeHugger Robot
29bcb287b6 Merge "MTP: Add support of ObjectInfoChanged Event" 2018-08-23 01:38:39 +00:00
Wei Jia
43d77dd7b3 MediaPlayer2: add clearNextDataSources.
Test: cts
Bug: 111657231
Change-Id: Ibe4cb7c7c57b3245e408ae004041338f9fc32bc4
2018-08-22 14:16:27 -07:00
Ari Hausman-Cohen
d5b5161007 Merge "Add Dynamic Source Effects" 2018-08-20 19:47:35 +00:00
Mathew Inwood
49e1c134af resolve merge conflicts of 2382108d01 to stage-aosp-master
Bug: None
Test: I solemnly swear I tested this conflict resolution.
Change-Id: I28c80f9ecb1c04a09d1be78503a716d26f66aff4
Merged-In: I3bd40136d7fc948f66eca6b2d139c15e39c5a248
2018-08-20 11:29:16 +01:00
Mathew Inwood
473b9d5bfc Add @UnsupportedAppUsage annotations
For packages:
  android.media.tv
  android.media.soundtrigger
  android.media.session
  android.media.projection
  android.media.midi
  android.media.effect.effects
  android.media.effect
  android.media.browse
  android.media.audiopolicy
  android.media.audiofx
  android.media

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: I9b58cb2d1e02d9156a7b0d19c1feff4bcd2c53a9
Merged-In: I3bd40136d7fc948f66eca6b2d139c15e39c5a248
2018-08-17 09:07:01 +01:00
Mathew Inwood
31a792ac29 Add @UnsupportedAppUsage annotations
For packages:
  android.media.tv
  android.media.soundtrigger
  android.media.session
  android.media.projection
  android.media.midi
  android.media.effect.effects
  android.media.effect
  android.media.browse
  android.media.audiopolicy
  android.media.audiofx
  android.media

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: I3bd40136d7fc948f66eca6b2d139c15e39c5a248
2018-08-17 08:54:26 +01:00
Mathew Inwood
345a4af9af Merge "Code reformatting for upcoming automated code changes." am: 43f3f60ec0 am: d9b640cbc2
am: 17ea268961

Change-Id: Ia86c739b9e02e963f3c74b25d67b7663860518bd
2018-08-16 18:44:12 -07:00
Mathew Inwood
d9b640cbc2 Merge "Code reformatting for upcoming automated code changes."
am: 43f3f60ec0

Change-Id: Id11efe22dffc7edd46d5dc2244b7121f664fba4d
2018-08-16 16:56:06 -07:00
Treehugger Robot
43f3f60ec0 Merge "Code reformatting for upcoming automated code changes." 2018-08-16 07:45:35 +00:00
Mathew Inwood
3ef2a833ba Merge "Add @UnsupportedAppUsage annotations"
am: 9feefd2f5f

Change-Id: Id93bdaf74cf2e9077f3af8367189ae98e8a2f95a
2018-08-15 06:52:39 -07:00
Gerry Fan
4f8c0a3d2b Merge "Add Nullable to MediaHTTPService's mCookies." am: 7955aec0ea am: 293800c9c9
am: d8a13d8215

Change-Id: Ibde8fec798d965ac6a2ecaf297008f93439f1419
2018-08-15 04:43:45 -07:00
Mathew Inwood
9feefd2f5f Merge "Add @UnsupportedAppUsage annotations" 2018-08-15 11:37:37 +00:00
Mathew Inwood
217f30b3a4 Merge "Add @UnsupportedAppUsage annotations" 2018-08-15 10:03:53 +00:00
Jeff Sharkey
d4be638911 Merge "Change MEDIA_TYPE through Files table." 2018-08-15 04:14:28 +00:00
Gerry Fan
293800c9c9 Merge "Add Nullable to MediaHTTPService's mCookies."
am: 7955aec0ea

Change-Id: Ic2073e516495b37d6e22867180eb687afebaf7f8
2018-08-14 20:19:50 -07:00
Ari Hausman-Cohen
a555e741d2 Add Dynamic Source Effects
Adds support for adding/removing effects to the list of
default effects for a given input source type.

Bug: 78527120
Test: Builds, manually tested with app that adds source effects,
additionally tested by Android Things integration tests making use
of this API.

Change-Id: Ibac324567e4df2888dccabd1e824c4cc51ad3644
2018-08-14 17:21:14 -07:00
gfan
73371d7503 Add Nullable to MediaHTTPService's mCookies.
Bug: 29321867
Test: manually tested with ndk sample native-audio
Change-Id: Ic30fe7c28db0111ee5bcb91b037b7c4536dcfd06
2018-08-14 15:10:49 -07:00
Jeff Sharkey
fac57e600d Change MEDIA_TYPE through Files table.
As part of implementing strongly-typed storage in the Q release, we've
needed to limit the items visible in strongly-typed views.  (For
example, the Images view must only include images.)

This change fixes a place inside the OS that was implicitly relying on
update() leaking between these strong data types.  If we're changing
the media type of an already-scanned file, we need to do that through
the Files table first, and then we can update the details at the
strongly-typed Uri.

Bug: 112467162
Test: atest android.media.cts.MediaScannerTest
Change-Id: I61c8b62e04f6542882745a20e9aed96275427b5f
2018-08-14 15:07:32 -06:00
Wei Jia
7f0e9e3dfe MediaPlayer2: add MEDIA_INFO_DATA_SOURCE_REPEAT
Test: cts
Bug: 109928575
Change-Id: Id628d88f3115e034d6d17523399ecb3f6a9bd249
2018-08-10 17:35:15 -07:00
Mathew Inwood
f82c47fc72 Merge "Add @UnsupportedAppUsage annotations" am: 3610ca221d
am: 72667caaa6

Change-Id: Ie078503a741307be16ce19587b6b29cf6fa32d01
2018-08-10 08:29:10 -07:00
Mathew Inwood
d237a74ff4 Add @UnsupportedAppUsage annotations
For packages:
  android.service.wallpaper
  android.service.vr
  android.service.voice
  android.service.trust
  android.service.textservice
  android.service.restrictions
  android.service.resolver
  android.service.quicksettings
  android.service.power
  android.service.pm
  android.service.persistentdata
  android.service.oemlock
  android.service.notification
  android.service.media
  android.service.gatekeeper
  android.service.fingerprint
  android.service.euicc
  android.service.dreams
  android.service.diskstats
  android.service.chooser
  android.service.carrier
  android.service.battery
  android.service.autofill
  android.service.appwidget
  android.service

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: I50fb66b55bbc82cc505b483c98f8bd09ae0b5020
Merged-In: I51645d8a8cdce3015749fc27e34830e822ef41ae
2018-08-10 09:58:47 +01:00
Mathew Inwood
e3807372f7 Add @UnsupportedAppUsage annotations
For packages:
  android.service.wallpaper
  android.service.vr
  android.service.voice
  android.service.trust
  android.service.textservice
  android.service.restrictions
  android.service.resolver
  android.service.quicksettings
  android.service.power
  android.service.pm
  android.service.persistentdata
  android.service.oemlock
  android.service.notification
  android.service.media
  android.service.gatekeeper
  android.service.fingerprint
  android.service.euicc
  android.service.dreams
  android.service.diskstats
  android.service.chooser
  android.service.carrier
  android.service.battery
  android.service.autofill
  android.service.appwidget
  android.service

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: I51645d8a8cdce3015749fc27e34830e822ef41ae
2018-08-10 09:51:03 +01:00
Mathew Inwood
c97c5c04f1 Add @UnsupportedAppUsage annotations
For packages:
  android.mtp

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: I6af7c9405b0ac3c2d30307dd04d6d330cd22bda4
Merged-In: Id97d70dc1003cd7c6ed585d647bf0df0fd7a946a
2018-08-09 17:29:53 +01:00
Mathew Inwood
d99b96e0f8 Add @UnsupportedAppUsage annotations
For packages:
  android.mtp

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: Id97d70dc1003cd7c6ed585d647bf0df0fd7a946a
2018-08-09 17:22:11 +01:00
Mathew Inwood
a44c098996 Code reformatting for upcoming automated code changes.
Adding annotations to individual fields cannot be easily done when there
are two fields defined in a single statement. Put each definition in a
statement of its own.

See go/UnsupportedAppUsage for more context.

Bug: 110868826
Test: m
Change-Id: I7c521973bd8856414b2d2e39573d887e426c69fc
2018-08-08 15:25:51 +01:00
Ari Hausman-Cohen
971cac75f7 Merge changes from topic "dynamic_stream_effects_master"
* changes:
  Add Dynamic Stream Effects
  Add permission for dynamic AudioEffect attachment
2018-08-02 23:10:52 +00:00
TreeHugger Robot
f15bbe2e8d Merge "MediaPlayer2: fix MEDIA_INFO_DATA_SOURCE_* events" 2018-08-01 17:57:07 +00:00
Wei Jia
08827e4b9a MediaPlayer2: fix MEDIA_INFO_DATA_SOURCE_* events
Test: cts test
Bug: 109928575
Change-Id: Id333c9447f3621147afff21ee375340e0e6be5ce
2018-07-31 17:05:13 -07:00
Jeff Tinker
17716ac974 Fix typo in MediaDrm.java
bug:78248792
Change-Id: I584762c2b2febb4abf05361062bdd3d7d78f49e7
2018-07-30 15:21:22 -07:00
Wei Jia
de9c74d0f4 MediaPlayer2: clean up setNextDataSource/s
Test: cts tests
Bug: 109928575
Change-Id: I3e8c0113b35d8b5f4e95ef3748d056aa3b162038
2018-07-27 15:29:01 -07:00
Ari Hausman-Cohen
7d54c5d838 Add Dynamic Stream Effects
Adds support for adding/removing effects to the list of
default effects for a given stream usage.

Bug: 78527120
Test: Builds, manually tested with app that adds stream effects,
additionally tested by Android Things integration tests making use
of this API.
Change-Id: I9fc262260c08046e59d57710ee2028499b0c2b94
2018-07-27 12:41:47 -07:00
James
e4f680e058 MTP: Add support of ObjectInfoChanged Event
Under MTP mode, new file created at device side shown size zero at PC side
due to file information is not updated to PC in time with ObjectAdded event

Bug: 77883345
Test: 1. Take screenshot of device under MTP mode with Win10 / Linux
    2. file copy, delete, rename between PC and device
    3. file copy, delete, rename on device with adb shell command
Test: adb shell am instrument -w android.mtp/
	android.support.test.runner.AndroidJUnitRunner

Change-Id: If428064fb0104b53b8afd5b050a4fab4a09312f0
2018-07-27 11:54:43 +08:00
TreeHugger Robot
306afa8652 Merge "Fix data source for HEIF exif extractor" 2018-07-27 02:16:42 +00:00
Chong Zhang
c139d46910 Fix data source for HEIF exif extractor
Do not allow the source to read past available bytes, since
the underlying input stream may not be able to seek after that.

For input streams from files, the available bytes is usually the
file size, and we usually don't have problem when the file is
of decent size. But when the file is very small, some of the
extractors (other than mp4) would request bytes past the end
of the file, which goes over the available range. Once that
condition is hit, we can't reset to the offet needed for
mp4 extractor and heif parsing would fail.

bug: 111897855
test: open heic files of various sizes in Files (Downloads) app,
check that ExifInterface shouldn't encounter any exceptions.

Change-Id: I668ff900f4155dc310cb7ea8977bbe091791c5d7
2018-07-26 17:01:28 -07:00
Jaewan Kim
4f5e805907 MediaSessionManager: Prevent volume keys from being ignored
When the volume key is pressed and the foreground activity doesn't
handle the event, the foreground activity tells the MediaSessionService
for adjusting system volume with its package name returned by
Context#getPackageName().

However, if the foreground process runs on another application's process
by specifying android:process in the AndroidManifest.xml. (e.g.
ApnSettingsActivity in the Settings), its package name wouldn't match
with the UID returned by the Binder.getCallingUid(). Because of the
mismatch, the app ops check in the AudioService will fail and
SecurityException will be thrown.

This fixes the issue by two ways
  1. Use Context#getOpPackageName() for sending package name.
  2. Use system service's package name and UID when adjusting volume
     with the hardware volume key presses.

Bug: 110525559
Test: Verified manually that the issue doesn't happen.
      And run all media CTS
Change-Id: I8bba691a36cbe442212aab3f0b23c97533009052
2018-07-25 08:58:23 +00:00
TreeHugger Robot
bd2a8811f3 Merge "Replace streams with Lists in MtpStorageManager" 2018-07-25 06:16:27 +00:00
TreeHugger Robot
cc74108336 Merge "Update Dolby surround sound display names" 2018-07-19 23:31:35 +00:00
Jerry Zhang
9a018747be Replace streams with Lists in MtpStorageManager
Streams are dispreferred in Android java, so
use Lists for all cases instead.

Test: Mtp works and MtpStorageManager tests pass
Change-Id: I0579013fca690346c6c2561fe3079fd50f215833
2018-07-16 18:21:47 -07:00
Robert Shih
507537ee16 Merge changes from topic "am-9e4fa925-b00a-40e6-8fb0-e5a4244e6284" into oc-dev am: e43837e258 am: dccb62bcca am: 64cb4be887 am: c450d1401e
am: deb8dbad23

Change-Id: I15c3a600ff4e4802254bb41d4903eec10583febc
2018-07-16 14:20:21 -07:00
Robert Shih
deb8dbad23 Merge changes from topic "am-9e4fa925-b00a-40e6-8fb0-e5a4244e6284" into oc-dev am: e43837e258 am: dccb62bcca am: 64cb4be887
am: c450d1401e

Change-Id: I7aba9ed971773ac2ea8cc7df5fe42ed9c022a5ab
2018-07-16 13:58:38 -07:00
Robert Shih
c450d1401e Merge changes from topic "am-9e4fa925-b00a-40e6-8fb0-e5a4244e6284" into oc-dev am: e43837e258 am: dccb62bcca
am: 64cb4be887

Change-Id: Id7d4599c5d7d7c803e86afa88be582773c80741f
2018-07-16 13:38:43 -07:00
Robert Shih
64cb4be887 Merge changes from topic "am-9e4fa925-b00a-40e6-8fb0-e5a4244e6284" into oc-dev am: e43837e258
am: dccb62bcca

Change-Id: I9e6762b25f001e31da7df0bb25984856989b9fd9
2018-07-16 13:13:13 -07:00
Robert Shih
dccb62bcca Merge changes from topic "am-9e4fa925-b00a-40e6-8fb0-e5a4244e6284" into oc-dev
am: e43837e258

Change-Id: Ib0ef741f0188ff3e6edc52e20eae997e9dba56e4
2018-07-16 12:51:28 -07:00
Chong Zhang
71ffe730af Merge "Fix broken javadoc link in MediaFormat" into pi-dev am: 15ae72085f
am: 741bcbee62

Change-Id: I87362a09b014b48ca1d8317d59bd355064cb463f
2018-07-16 12:33:46 -07:00
Chong Zhang
741bcbee62 Merge "Fix broken javadoc link in MediaFormat" into pi-dev
am: 15ae72085f

Change-Id: Id7af6bea28f60e93ce1a1cce94f053b9484ceb37
2018-07-16 12:25:32 -07:00
Dean Wheatley
1ba2d5ea79 Update Dolby surround sound display names
Bug: 63901775
Test: make
Change-Id: I27b969067c210c1684cbc53db3fade6175795498
2018-07-13 14:22:51 -07:00
Android Build Merger (Role)
7b414ce710 [automerger] Fix TrackInfo parcel write am: 0d2dc943dc am: 00b57fc9b7 am: 1bce1217ca am: 47c831e675 am: d6143e9307
Change-Id: I67d3d47cf3ba616d8b8d963d7092895621f63200
2018-07-13 06:57:21 +00:00