Issue 129 now makes it easy to specify a Gin module in a GWT module .xml file.
However, it is still impossible to make a binding depend on a GWT property
(such as, say, `user.agent`). As a result, the only way to instantiate
browser-dependant classes is to leave it unbound and rely on Gin using
GWT.create() to create them. The drawback is that any injected field is left
uninitialized.
I'm not sure of the best way to enable that feature. Things we could consider,
from simple (but less interesting) to more involved:
* Injecting @inject fields in classes instantiated with GWT.create and asking the user the rely on <replace-with>.
* Conditionally switching Gin modules based on GWT properties
* Having some kind of conditionalBind() mechanism.
Original issue reported on code.google.com by philippe.beaudoin on 24 Apr 2011 at 4:21
Original issue reported on code.google.com by
philippe.beaudoin
on 24 Apr 2011 at 4:21