Commit Graph

11 Commits

Author SHA1 Message Date
Hugh Chen
40d4e47b05 Add the explicitly mutable flag for creating a PendingIntent
- Android S+ to specify explicitly either FLAG_MUTABLE or FLAG_IMMUTABLE
  when creating a PendingIntent.
- Suggest to use the FLAG_IMMUTABLE as default. Change it to
  FLAG_MUTABLE while errors occur.

Fixes: 172207262
Fixes: 172207195
Fixes: 172205385
Fixes: 172204525
Fixes: 172205897
Test: build pass, manual test to paring blutooth device and doing
seamless transfer

Change-Id: Ic37b37bdbe6de6bdbad741985d3a920334240d80
2020-11-04 10:59:34 +08:00
timhypeng
eee759ea29 Update rule of launching media output dialog
-Do not hide Media Output Dialog in Settings, and let dialog handles
-Hide Media output slice panel when launching dialog

Bug: 155822415
Test: make -j50 RunSettingsRoboTests
Change-Id: I16732f625f100b259d6e53c85db40af0ec1652c5
2020-10-08 16:29:28 +08:00
timhypeng
3084d063f3 Update OutputSwitcher from MediaOutputSlice to MediaOutputDialog in Settings
-Update entry point at media indicator in volume panel
-Update entry point at remote media slice in volume panel
-Update entry point at remote volume group in Sound Settings
-Update entry point at media output preference in Sound Settings
-Hide Media output dialog when the caller is not active

Bug: 155822415
Test: make -j50 RunSettingsRoboTests
Change-Id: Ib6c86067522925c439f336644e4d027dbae3379c
2020-10-08 16:18:43 +08:00
Hugh Chen
c07b475843 Move isMediaOutputDisabled() from Utils to LocalMediaManager
- Move isMediaOutputDisabled() from Utils to LocalMediaManager.
  The isMediaOutputDisabled() is used to check whether should
  disable the entry point of media output, it's not a general
  method for Settings. To reduce the usage of Utils.java,
  it's better to let LocalMediaManager handle this method.
- Add test cases.

Bug: 169378895
Test: make -j42 RunSettingsRoboTests
Change-Id: I5dbed2ad4de6dca8105414f8b7d7ce7141e258bd
2020-09-29 11:27:39 +08:00
Hugh Chen
b6840ced0d Disable entry point of output switcher
It adds a minimum value if it shows only one available
cast device in the output switcher. Because users can only
change the volume slider or stop control in the output switcher.
It's too hidden to have the user stop cast in the UI.

- This CL will disable the entry point of the output switcher
  if there is only one available cast device in the list.
- Update test cases.

Bug: 163095048
Test: make -j42 RunSettingsRoboTests
Change-Id: I8906878e1ba769d6940041f17d83b5de6b2a32c0
2020-09-25 02:38:19 +00:00
Hugh Chen
c3fe8d87d6 Fix output switcher will display previous media session
Before this CL, the same request code will cause intent to
be cached. It will cause the output switcher to display the
previous media session.

This CL uses the package name as an unique request code to
fix this issue.

Bug: 169077753
Test: make -j42 RunSettingsRoboTests
Change-Id: Iebfc7904609e243d5bf0222307bae98a952a3331
2020-09-23 10:20:19 +08:00
Hugh Chen
7f3efd4357 Fix cast volume control bar not work
Use hashcode as a requestCode id, since the
same requestCode will cause the intent be cached.

Bug: 163095633
Test: make -j42 RunSettingsRoboTests
Change-Id: I2c120f18e24a66aeff5565e952fa4064149ec540
2020-08-31 15:48:46 +08:00
Tim Peng
2ef5a87f36 Update "Play media to" to "Play <APP> on"
-Update in Volume panel and Sound settings
-Add test cases

Bug: 155345595
Test: make -j50 RunSettingsRoboTests
Change-Id: Id971038ddbf22924a747e4e1be3597face7ec6ed
2020-05-06 10:17:15 +08:00
Tim Peng
e9b91f08c4 Modify rule of remote media session UI
-Add preference by remote session in Sound Setting
-Add slice item by remote session in Volume panel
-Replace media device data with media session data
-Add test case

Bug: 154918214
Test: make -j50 RunSettingsRoboTests
Change-Id: Ib1c873c9f99eebcba377f4115c4b9b4297b20c3d
2020-05-04 12:21:20 +08:00
Tim Peng
2688639b05 Add package name when launching output switcher from remote slice
Bug: 150742783
Test: make -j42 RunSettingsRoboTests
Change-Id: I670870cd314dc9a51d7a9a58837b95b4b8cf8808
2020-03-04 13:30:41 +08:00
timhypeng
b266fa6029 Add remote media slice in volume panel
-Add test cases

Bug: 142772656
Test: make -j42 RunSettingsRoboTests
Change-Id: I62d3054a4343ed2c7fbb0b4d7aeb5a48da194b02
2020-02-06 14:38:13 +08:00