| Index: chrome/browser/media/router/mojo/media_router.mojom
|
| diff --git a/chrome/browser/media/router/mojo/media_router.mojom b/chrome/browser/media/router/mojo/media_router.mojom
|
| index 683904122489d906d2ffbca2765f76648c824c13..e0900c4ed07ae058c06cbcb791f479827e82c23c 100644
|
| --- a/chrome/browser/media/router/mojo/media_router.mojom
|
| +++ b/chrome/browser/media/router/mojo/media_router.mojom
|
| @@ -114,6 +114,13 @@ struct RouteMessage {
|
| array<uint8>? data;
|
| };
|
|
|
| +struct SinkSearchCriteria {
|
| + // Arbitrary string input to the search method.
|
| + string input;
|
| + // The user's current hosted domain.
|
| + string domain;
|
| +};
|
| +
|
| // Maps to a ResultCode value in route_request_result.h
|
| // The enum defined here is a subset of those defined in route_request_result.h.
|
| enum RouteRequestResultCode {
|
| @@ -286,6 +293,24 @@ interface MediaRouteProvider {
|
| // Calling this will trigger a firewall prompt on Windows if there is not
|
| // already a firewall rule for mDNS.
|
| EnableMdnsDiscovery();
|
| +
|
| + // Indicates that the Media Router is interested in finding a sink that
|
| + // matches |search_criteria| and is compatible with the source urn
|
| + // |media_source|. The user's current domain is also used to search. If a sink
|
| + // is found, a route is also created from |media_source| to the new sink. The
|
| + // parameters beyond |search_criteria| will be forwarded to CreateRoute if a
|
| + // sink is found.
|
| + SearchSinksAndCreateRoute(string sink_id,
|
| + string media_source,
|
| + SinkSearchCriteria search_criteria,
|
| + string presentation_id,
|
| + string origin,
|
| + int32 tab_id,
|
| + int64 timeout_millis,
|
| + bool off_the_record) =>
|
| + (MediaRoute? route,
|
| + string? error_text,
|
| + RouteRequestResultCode result_code);
|
| };
|
|
|
| // Interface for a service which observes state changes across media
|
| @@ -330,6 +355,12 @@ interface MediaRouter {
|
| OnSinksReceived(string media_source, array<MediaSink> sinks,
|
| array<string> origins);
|
|
|
| + // Called when the Media Route Manager has found a sink for a current search
|
| + // to inform the MR and UI of the ID of the new sink. The sink object itself
|
| + // will be returned in the next OnSinksReceived() as part of the normal sink
|
| + // list update process. |pseudo_sink_id| identifies the current search.
|
| + OnSearchSinkIdReceived(string pseudo_sink_id, string sink_id);
|
| +
|
| // Called when issues are reported for media routes.
|
| OnIssue(Issue issue);
|
|
|
|
|