CastTile: Set media router group id to sync cast status
Using media router group id, CastTile can sync cast status with Settings. If Settings begins/stops cast (mirrorring), CastTile can know that and Settings also knows when CastTile begins cast. Please refer ag/7669852 to how router group id can be used to synchronize cast status. Bug: 112826114 Bug: 131385091 Bug: 130345243 Test: Manually tested after applying this and ag/7708778 Change-Id: Ie7c329220eb67725515517c950ff476cbee733c0
This commit is contained in:
@@ -71,6 +71,7 @@ public class CastControllerImpl implements CastController {
|
||||
public CastControllerImpl(Context context) {
|
||||
mContext = context;
|
||||
mMediaRouter = (MediaRouter) context.getSystemService(Context.MEDIA_ROUTER_SERVICE);
|
||||
mMediaRouter.setRouterGroupId(MediaRouter.MIRRORING_GROUP_ID);
|
||||
mProjectionManager = (MediaProjectionManager)
|
||||
context.getSystemService(Context.MEDIA_PROJECTION_SERVICE);
|
||||
mProjection = mProjectionManager.getActiveProjectionInfo();
|
||||
|
||||
Reference in New Issue
Block a user