Re: [presentation-api] First version of postMessage and onmessage algorithms

Thanks for putting this together, comments:

Indent the following to match the rest of the definition.   Also the 
first instance of 'postMessage' is bold while other declarations are 
not.

```
// Communication
attribute BinaryType binaryType;
EventHandler onmessage;
void postMessage (DOMString message);
void postMessage (Blob data);
void postMessage (ArrayBuffer data);
void postMessage (ArrayBufferView data);
```

> the data contents of a transmission between two browsing contexts

Does this mean a single invocation of `postMessage()`?  I think it 
would be permissible for the implementation to fragment transmission 
(e.g. to meet the requirements of a network transport) of a single 
message.  Can it be clarified?

> Let presentation message format be the format of that data, one of 
Text and Binary.

I think of this as a type, not a format; the text data could be sent 
in a binary format if the implementation chooses.  So maybe: "Let 
*presentation message type* be the type of that data, one of `text` or
 `binary`."

> (Set to Binary if data is one of ArrayBuffer or Blob. Set to Text if
 data is of type DOMString)

This would be clearer as its own step.

> to the remote side, i.e. from opening browsing context to 
presentation browsing context or vice versa

Maybe just "to the destination browsing context"?  Or have a step that
 defines the destination context for the data?

>the URL that the opening browsing context and the presenting browsing
 context have in common.

What if they have no URL in common?

> If the presentation message format is Text, then initialize event's 
data attribute to the contents of  presentation message data.

....as a DOMString?








 



-- 
GitHub Notif of comment by mfoltzgoogle
See 
https://github.com/w3c/presentation-api/pull/62#issuecomment-77641805

Received on Friday, 6 March 2015 21:45:23 UTC