Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 module media_router.interfaces; | 5 module media_router.interfaces; |
| 6 | 6 |
| 7 // Represents an output sink to which media can be routed. | 7 // Represents an output sink to which media can be routed. |
| 8 struct MediaSink { | 8 struct MediaSink { |
| 9 enum IconType { | 9 enum IconType { |
| 10 CAST, | 10 CAST, |
| (...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 294 CLOSED, | 294 CLOSED, |
| 295 WENT_AWAY | 295 WENT_AWAY |
| 296 }; | 296 }; |
| 297 | 297 |
| 298 // Registers a MediaRouteProvider with the MediaRouter. | 298 // Registers a MediaRouteProvider with the MediaRouter. |
| 299 // Returns a string that uniquely identifies the Media Router browser | 299 // Returns a string that uniquely identifies the Media Router browser |
| 300 // process. | 300 // process. |
| 301 RegisterMediaRouteProvider(MediaRouteProvider media_router_provider) => | 301 RegisterMediaRouteProvider(MediaRouteProvider media_router_provider) => |
| 302 (string instance_id); | 302 (string instance_id); |
| 303 | 303 |
| 304 // Called when the Media Route Manager receives a new list of sinks. | 304 // Called when the Media Route Manager receives a new list of sinks |
|
mark a. foltz
2016/03/11 01:20:23
s/sinks//
imcheng
2016/03/14 21:30:20
Done.
| |
| 305 OnSinksReceived(string media_source, array<MediaSink> sinks); | 305 // |sinks| compatible with |media_source|. The result is only valid for |
| 306 // |origins|. If |origins| is empty, the result is valid for any origin. | |
| 307 OnSinksReceived(string media_source, array<MediaSink> sinks, | |
| 308 array<string> origins); | |
| 306 | 309 |
| 307 // Called when issues are reported for media routes. | 310 // Called when issues are reported for media routes. |
| 308 OnIssue(Issue issue); | 311 OnIssue(Issue issue); |
| 309 | 312 |
| 310 // Called when list of routes has been updated in the context of the | 313 // Called when list of routes has been updated in the context of the |
| 311 // calling |media_source|. The array |joinable_route_ids| should | 314 // calling |media_source|. The array |joinable_route_ids| should |
| 312 // contain route IDs of joinable routes found in the |routes| array. | 315 // contain route IDs of joinable routes found in the |routes| array. |
| 313 OnRoutesUpdated(array<MediaRoute> routes, string media_source, | 316 OnRoutesUpdated(array<MediaRoute> routes, string media_source, |
| 314 array<string> joinable_route_ids); | 317 array<string> joinable_route_ids); |
| 315 | 318 |
| 316 // Called when the overall availability of media sinks has been updated. | 319 // Called when the overall availability of media sinks has been updated. |
| 317 OnSinkAvailabilityUpdated(SinkAvailability availability); | 320 OnSinkAvailabilityUpdated(SinkAvailability availability); |
| 318 | 321 |
| 319 // Called when the state of presentation connected to route |route_id| has | 322 // Called when the state of presentation connected to route |route_id| has |
| 320 // changed to |state|. | 323 // changed to |state|. |
| 321 OnPresentationConnectionStateChanged( | 324 OnPresentationConnectionStateChanged( |
| 322 string route_id, PresentationConnectionState state); | 325 string route_id, PresentationConnectionState state); |
| 323 | 326 |
| 324 // Called when the presentation connected to route |route_id| has closed. | 327 // Called when the presentation connected to route |route_id| has closed. |
| 325 OnPresentationConnectionClosed( | 328 OnPresentationConnectionClosed( |
| 326 string route_id, PresentationConnectionCloseReason reason, | 329 string route_id, PresentationConnectionCloseReason reason, |
| 327 string message); | 330 string message); |
| 328 }; | 331 }; |
| 329 | 332 |
| OLD | NEW |