Commit e7d1523e authored by jrummell@chromium.org's avatar jrummell@chromium.org

Add promise type to EME idl files

Now that the Blink IDL supports the Promise<T> syntax, update
the EME idl files with the promise type.

BUG=358271
TEST=existing EME tests pass

Review URL: https://codereview.chromium.org/694773004

git-svn-id: svn://svn.chromium.org/blink/trunk@185152 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 7024e9df
...@@ -39,13 +39,13 @@ ...@@ -39,13 +39,13 @@
[CallWith=ScriptState] readonly attribute Promise closed; [CallWith=ScriptState] readonly attribute Promise closed;
// session initialization // session initialization
[CallWith=ScriptState] Promise generateRequest(DOMString initDataType, ArrayBuffer initData); [CallWith=ScriptState] Promise<void> generateRequest(DOMString initDataType, ArrayBuffer initData);
[CallWith=ScriptState] Promise generateRequest(DOMString initDataType, ArrayBufferView initData); [CallWith=ScriptState] Promise<void> generateRequest(DOMString initDataType, ArrayBufferView initData);
[CallWith=ScriptState] Promise load(DOMString sessionId); [CallWith=ScriptState] Promise<boolean> load(DOMString sessionId);
// session operations // session operations
[CallWith=ScriptState] Promise update(ArrayBuffer response); [CallWith=ScriptState] Promise<void> update(ArrayBuffer response);
[CallWith=ScriptState] Promise update(ArrayBufferView response); [CallWith=ScriptState] Promise<void> update(ArrayBufferView response);
[CallWith=ScriptState] Promise close(); [CallWith=ScriptState] Promise<void> close();
[CallWith=ScriptState] Promise remove(); [CallWith=ScriptState] Promise<void> remove();
}; };
...@@ -10,5 +10,5 @@ ...@@ -10,5 +10,5 @@
TypeChecking=Interface TypeChecking=Interface
] interface MediaKeySystemAccess { ] interface MediaKeySystemAccess {
readonly attribute DOMString keySystem; readonly attribute DOMString keySystem;
[CallWith=ScriptState] Promise createMediaKeys(); [CallWith=ScriptState] Promise<MediaKeys> createMediaKeys();
}; };
...@@ -35,8 +35,8 @@ enum SessionType { ...@@ -35,8 +35,8 @@ enum SessionType {
] interface MediaKeys { ] interface MediaKeys {
[CallWith=ScriptState] MediaKeySession createSession(optional SessionType sessionType = "temporary"); [CallWith=ScriptState] MediaKeySession createSession(optional SessionType sessionType = "temporary");
[CallWith=ScriptState] Promise setServerCertificate(ArrayBuffer serverCertificate); [CallWith=ScriptState] Promise<void> setServerCertificate(ArrayBuffer serverCertificate);
[CallWith=ScriptState] Promise setServerCertificate(ArrayBufferView serverCertificate); [CallWith=ScriptState] Promise<void> setServerCertificate(ArrayBufferView serverCertificate);
static boolean isTypeSupported(DOMString keySystem, optional DOMString contentType = null); static boolean isTypeSupported(DOMString keySystem, optional DOMString contentType = null);
}; };
...@@ -7,5 +7,5 @@ ...@@ -7,5 +7,5 @@
[ [
RuntimeEnabled=EncryptedMedia RuntimeEnabled=EncryptedMedia
] partial interface Navigator { ] partial interface Navigator {
[CallWith=ScriptState] Promise requestMediaKeySystemAccess(DOMString keySystem, optional sequence<MediaKeySystemOptions> supportedConfigurations); [CallWith=ScriptState] Promise<MediaKeySystemAccess> requestMediaKeySystemAccess(DOMString keySystem, optional sequence<MediaKeySystemOptions> supportedConfigurations);
}; };
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment