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

Unified Diff: content/common/presentation/presentation_service.mojom

Issue 979413002: [Presentation API] Additional plumbing for PresentationServiceImpl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@REAL-NEW-MASTER
Patch Set: Added handling for overlapping requests, default presentation id, 1-UA fallback Created 5 years, 9 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: content/common/presentation/presentation_service.mojom
diff --git a/content/common/presentation/presentation_service.mojom b/content/common/presentation/presentation_service.mojom
index d1e4b07909b59f888cd7f09433da54fcdb0742c0..6dd29b6390acbd60ace951d14bb2816255c4fb6a 100644
--- a/content/common/presentation/presentation_service.mojom
+++ b/content/common/presentation/presentation_service.mojom
@@ -7,7 +7,6 @@ module presentation;
import "presentation_session.mojom";
struct PresentationSessionInfo {
- PresentationSession session;
string url;
string id;
};
@@ -20,11 +19,17 @@ enum PresentationErrorType {
};
struct PresentationError {
- PresentationErrorType errorType;
+ PresentationErrorType error_type;
string message;
};
interface PresentationService {
+ // Called when the browser parses the specified default presentation URL or
+ // presentation ID.
+ SetDefaultPresentationUrl(
+ string default_presentation_url,
+ string? default_presentation_id);
+
// Returns the last screen availability state if it’s changed since the last
// time the method was called. The client has to call this method again when
// handling the result (provided via Mojo callback) to get the next update
@@ -33,11 +38,12 @@ interface PresentationService {
// stop discovery once there are no active calls to GetScreenAvailability.
// |presentation_url| can be specified to help the implementation to filter
// out incompatible screens.
- GetScreenAvailability(string? presentation_url) => (bool available);
+ GetScreenAvailability(string? presentation_url) =>
+ (string? presentation_url, bool available);
// Called when the frame no longer listens to the
// |availablechange| event.
- OnScreenAvailabilityListenerRemoved();
+ OnScreenAvailabilityListenerRemoved(string? presentation_url);
// Called when startSession() is called by the frame. The result callback
// will return a non-null and valid PresentationSessionInfo if starting the
@@ -50,7 +56,7 @@ interface PresentationService {
// rather than get a new one. An empty presentation id means that the
// UA will generate the presentation id.
StartSession(string presentation_url, string? presentation_id)
- => (PresentationSessionInfo? sessionInfo, PresentationError? error);
+ => (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
@@ -58,4 +64,4 @@ interface PresentationService {
// silently and without user action.
JoinSession(string presentation_url, string? presentation_id)
=> (PresentationSessionInfo? sessionInfo, PresentationError? error);
-};
+};

Powered by Google App Engine
This is Rietveld 408576698