locked
share contract item generates wrong code?

    Question

  • Hello again.

    After using the add new item dialog, I've noticed that the code generated by the share contract option isn't correct:

     in the activated event, it tests for the presence of a thumbnail and then id tries to call the getStreamAsync method:

    var thumbnail = share.data.properties.thumbnail;
                if (thumbnail) {
                    // If the share data includes a thumbnail, display it.
                    thumbnail.getStreamAsync().then(function (stream) {
                        var blob = window.msWWA.createBlobFromRandomAccessStream("image/jpeg", stream);
                        document.querySelector(".shared-thumbnail").src = window.URL.createObjectURL(blob, false);
                    });
                } 

    It should call the openReadAsync method instead...


    Luis Abreu

    Saturday, May 05, 2012 9:47 PM

Answers

All replies