The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

bpetro (5) [Avatar] Offline
#1
This is ugly and the final fix may be to refactor, but half way into the project I learn we're supposed to pop up a new window and continue doing data queries in the new window. Everything I read indicates that this means we need a new module. However, the new module needs classes and stuff from the old module, while the original module needs to know about the new module so it can call it (I think it does anyway). SO! What I find is - GWT seems OK if I set BOTH modules to inherit each other - but I figure I better ask if this sounds ok?

Second problem. Regardless of if I do this double linking, I observed an oddity. I remove the second link for now and only inherit the new module in the original module... But since both modules have entry points, if I put a breakpoint in both modules onModuleLoad() I find that the com.google.gwt.dev.shell.ModuleSpace during bootstrap process sees BOTH entry points and hands each of them into their onModuleLoad() to touch the page that is coming up. THIS SEEMS VERY WRONG.

So the second problem is by far the most troublesome. What am I doing wrong here? Is it wrong to have two entry points? I don't think so, but I don't know.

Suggestions?
robert.hanson (173) [Avatar] Offline
#2
Re: What are the GWT module rules in 1.6?
> GWT seems OK if I set BOTH modules to inherit each other - but I figure I
> better ask if this sounds ok?

No problem with doing this, but it could indicate a design issue.

> bootstrap process sees BOTH entry points

Simple solution... don't include two entry points.

You aren't limited to only a single module configuration file for each project. Add a second module configuration file to each project without the entry point, and when project A inherits from project B, point to the config in B without the entry point (and visa versa)..

Ideally though, I recommend refactoring your project. App1 in one project, App2 in a second, and shared code in a third.