Updated patch with suggestions.

http://gwt-code-reviews.appspot.com/1451818/diff/5001/user/src/com/google/gwt/core/client/ScriptInjector.java
File user/src/com/google/gwt/core/client/ScriptInjector.java (right):

http://gwt-code-reviews.appspot.com/1451818/diff/5001/user/src/com/google/gwt/core/client/ScriptInjector.java#newcode39
user/src/com/google/gwt/core/client/ScriptInjector.java:39: *
public void onFailure(Void reason) {
On 2011/06/20 20:35:52, bobv wrote:
Leaving reason as Void means there's no way to provide any kind of
diagnostic
message to the caller.  You could make this parameterized by Exception
to at
least be able to provide a message string, and possibly a
JavaScriptException if
one is warranted.

Done.  We already have a CodeDownloadException which is perfect for this
case.

http://gwt-code-reviews.appspot.com/1451818/diff/5001/user/src/com/google/gwt/core/client/ScriptInjector.java#newcode177
user/src/com/google/gwt/core/client/ScriptInjector.java:177: public
static final JavaScriptObject TOP_WINDOW = nativeTopWindow();
On 2011/06/20 20:35:52, bobv wrote:
Why would an external caller use use TOP_WINDOW?  If it's going to be
public,
javadoc it.

Done.

http://gwt-code-reviews.appspot.com/1451818/diff/8002/user/src/com/google/gwt/core/client/ScriptInjector.java#newcode73
user/src/com/google/gwt/core/client/ScriptInjector.java:73: public void
inject() {
On 2011/06/20 20:58:29, jlabanca wrote:
Can this return the script element?

I'm willing to make this change but I'm not sure what hte use case is?
Is it still a good thing to return the script element if its just been
removed from the DOM?

http://gwt-code-reviews.appspot.com/1451818/

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to