Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(234)

Unified Diff: third_party/WebKit/public/platform/modules/presentation/presentation.mojom

Issue 2174693004: [Presentation API] Add support to content/ for multiple URLs per PresentationRequest. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update service, dispatcher to use Mojo URLs. Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/public/platform/modules/presentation/presentation.mojom
diff --git a/third_party/WebKit/public/platform/modules/presentation/presentation.mojom b/third_party/WebKit/public/platform/modules/presentation/presentation.mojom
index cb5ce871cae6e63cb4357df4f6595aaa283a80ee..28fe1be5360baaa4e72ae208daebde316e4c1767 100644
--- a/third_party/WebKit/public/platform/modules/presentation/presentation.mojom
+++ b/third_party/WebKit/public/platform/modules/presentation/presentation.mojom
@@ -4,8 +4,10 @@
module blink.mojom;
+import "url/mojo/url.mojom";
+
struct PresentationSessionInfo {
- string url;
+ url.mojom.Url url;
string id;
};
@@ -52,20 +54,20 @@ interface PresentationService {
// Sets the PresentationServiceClient.
SetClient(PresentationServiceClient client);
- // Called when the frame sets or changes the default presentation URL.
+ // Called when the frame sets or changes the default presentation URLs.
// When the default presentation is started on this frame,
// PresentationServiceClient::OnDefaultSessionStarted will be invoked.
- SetDefaultPresentationURL(string url);
+ SetDefaultPresentationUrls(array<url.mojom.Url> presentation_urls);
// Starts listening for screen availability for presentation of
- // |url|. Availability results will be returned to the client via
+ // |availability_url|. Availability results will be returned to the client via
// PresentationServiceClient::OnScreenAvailabilityUpdated.
- ListenForScreenAvailability(string url);
+ ListenForScreenAvailability(url.mojom.Url availability_url);
// Stops listening for screen availability for the presentation of |url|. The
// PresentationServiceClient will stop receiving availability updates for
// |url|.
- StopListeningForScreenAvailability(string url);
+ StopListeningForScreenAvailability(url.mojom.Url availability_url);
// Called when startSession() is called by the frame. The result callback
// will return a non-null and valid PresentationSessionInfo if starting the
@@ -76,14 +78,14 @@ interface PresentationService {
// If the UA identifies a matching session (same presentation url), the user
// may choose this existing session and the page will join it rather than get
// a new one.
- StartSession(string presentation_url)
+ StartSession(array<url.mojom.Url> presentation_urls)
=> (PresentationSessionInfo? sessionInfo, PresentationError? error);
// Called when joinSession() is called by the frame. The result callback
// works the same as for the method above. JoinSession will join a known
// session (i.e. when the page navigates or the user opens another tab)
// silently and without user action.
- JoinSession(string presentation_url, string? presentation_id)
+ JoinSession(array<url.mojom.Url> presentation_urls, string? presentation_id)
=> (PresentationSessionInfo? sessionInfo, PresentationError? error);
// Called when send() is called by the frame. The true in the
@@ -95,10 +97,10 @@ interface PresentationService {
SessionMessage message_request) => (bool success);
// Called when close() is called by the frame.
- CloseConnection(string presentation_url, string presentation_id);
+ CloseConnection(url.mojom.Url presentation_url, string presentation_id);
// Called when terminate() is called by the frame.
- Terminate(string presentation_url, string presentation_id);
+ Terminate(url.mojom.Url presentation_url, string presentation_id);
// Starts listening for messages for session with |sessionInfo|.
// Messages will be received in
@@ -112,13 +114,13 @@ interface PresentationServiceClient {
// presentation of |url| but it is not supported by the device or underlying
// platform. This can also be called if the device is currently in a mode
// where it can't do screen discoveries (eg. low battery).
- OnScreenAvailabilityNotSupported(string url);
+ OnScreenAvailabilityNotSupported(url.mojom.Url url);
// Called when the client is listening for screen availability for
// presentation of |url| and the state changes. When the client starts to
// listen for screen availability, this method will always be called to give
// the current known state. It will then be called to notify of state updates.
- OnScreenAvailabilityUpdated(string url, bool available);
+ OnScreenAvailabilityUpdated(url.mojom.Url url, bool available);
// Called when the state of PresentationConnection |connection| started on
// this frame has changed to |newState|.

Powered by Google App Engine
This is Rietveld 408576698