Hello,
I am currently trying to create a Robot that adds a second gadget to a
wave. The way everything works currently is the following:
1. user adds my robot
2. an authentication gadget is added to the wavelet to help with OAuth
APIs and uer feedback as they log into the remote server
3. the robot goes through oauth magic and then accesses my logic
3. the user types a string command along the lines of "show <some
webpage>" where <show webpage> can be replaced with the name of a
website.
Now what should then happen is another, different gadget should be
added to the wave by the robot autmoatically, but this does not
occur. Does anyone else have this type of functionality going on? I
created some wrapper gadget adder methods to help add gadgets to a
wave:
public static Gadget getGadget(Event event, String gadgetLocation) {
GadgetView gadgetView =
event.getBlip().getDocument().getGadgetView
();
String gadgetUri = getGadgetUri(gadgetLocation);
return gadgetView.getGadget(gadgetUri);
}
public static Gadget addNewGadgetToWavelet(Event event, String
gadgetLocation) {
Gadget gadget = new Gadget(getGadgetUri(gadgetLocation));
event.getBlip().getDocument().getGadgetView().append(gadget);
return gadget;
}
private static String getGadgetUri(String gadgetLocation) {
return "http://my-robot.appspot.com/" + gadgetLocation;
}
however, it does not seem that
event.getBlip().getDocument().getGadgetView().append(gadget);
is doing anything with the second gadget.
I have verified that if i add this gadget with the first one (2
gadgets are appended when the wave is added), everything works fine.
but when i try to add the gadget at a later time, nothing occurs. The
gadget gets created fine, but it never gets appended to the TextView.
Has anyone else hit this issue, or is something going in the wave code
that is preventing this?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Wave API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-wave-api?hl=en
-~----------~----~----~----~------~----~------~--~---