am dbbfa702: Fix MediaRouter bugs

* commit 'dbbfa702a09f6d2d36dee1b552442d04a4673f89':
  Fix MediaRouter bugs
This commit is contained in:
Adam Powell
2012-06-24 14:56:06 -07:00
committed by Android Git Automerger

View File

@@ -240,7 +240,7 @@ public class MediaRouter {
for (int i = 0; i < count; i++) {
final CallbackInfo info = sStatic.mCallbacks.get(i);
if (info.cb == cb) {
info.type &= types;
info.type |= types;
return;
}
}
@@ -342,6 +342,7 @@ public class MediaRouter {
if (cat.isGroupable() && !(info instanceof RouteGroup)) {
// Enforce that any added route in a groupable category must be in a group.
final RouteGroup group = new RouteGroup(info.getCategory());
group.mSupportedTypes = info.mSupportedTypes;
sStatic.mRoutes.add(group);
dispatchRouteAdded(group);
group.addRoute(info);