You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@shindig.apache.org by Sachin Shenoy <sa...@google.com> on 2009/06/14 22:56:20 UTC

Re: [jira] Resolved: (SHINDIG-1049) requestSendMessage should use the RPC mechanism as similar features do

I had some doubt with changes in this patch.----
opensocial.requestSendMessage = function(recipients, message, opt_callback,
    opt_params) {
    gadgets.rpc.call(null, "requestSendMessage", opt_callback, recipients,
message, opt_callback,
        opt_params);
};
----

The callback requestSendMessage expects opensocial.ResponseItem.  How can I
form an instance of opensocial.ResponseItem at the container side and invoke
the callback that actually resides in gadget iframe? Are objects passed
across gadgets.rpc deserialized back to the right object? I thought they
would just get jsonified.

Also, With this patch we are forcing people to use the new mechanism. I
would have ideally liked the gadgets.rpc.call to be put in container.js and
have opensocial.js invoke it like,

opensocial.Container.get().requestSendMessage(recipients,
message, opt_callback, opt_params);

that way, none of the existing impl would have broken, and yet someone could
have impl. requestSendMessage without overriding any internals.

Thanks,
Sachin

On Sat, Jun 6, 2009 at 5:30 AM, Paul Lindner (JIRA) <ji...@apache.org> wrote:

>
>     [
> https://issues.apache.org/jira/browse/SHINDIG-1049?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel]
>
> Paul Lindner resolved SHINDIG-1049.
> -----------------------------------
>
>    Resolution: Fixed
>
> nice.
>
> committed.
>
>
> > requestSendMessage should use the RPC mechanism as similar features do
> > ----------------------------------------------------------------------
> >
> >                 Key: SHINDIG-1049
> >                 URL: https://issues.apache.org/jira/browse/SHINDIG-1049
> >             Project: Shindig
> >          Issue Type: Improvement
> >          Components: Javascript
> >    Affects Versions: trunk
> >            Reporter: Jordan Zimmerman
> >             Fix For: trunk
> >
> >         Attachments: fix-1049-bug.patch
> >
> >
> > Currently, in order for a container to implement requestSendMessage() it
> must overload Shindig internals. It would be far better to use the same
> method as for requestNavigateTo() etc.
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>