Hi again, I solved the problem, and now it works, as intended :) If somebody has any questions, how this works, just eMail me.
Greets Alex On 16 Aug., 15:37, AlexG <alexander.gauss.ax...@googlemail.com> wrote: > Hi, > > first thanks for your fast reply. > I think this should work. Perhaps I should just > give more background information. > > The App is build using the MVP Pattern. I have one > "main"-Page, with 3 Panels (3 div-elements in the .html) > > Two of the three panels will never change during runtime. These > contains the menu control-widgets. If i select something, > then the "content"-Panel should load the requestet UI (Module). > > This means, it should load just a new MVP-View via a new MVP > presenter. > The views and presenters are seperated in extra Projects in Eclipse, > just > to make it easy to maintain the App. > > So I definitely don´t want anything in one Project, or any widget in > one onModuleLoad(). I also don´t want lots of if´s to decide, which > view should be shown, because the app must be highly maintainable, > reusable > and extensable. > > By-the-way, the way I do it, works, if I code it with many if´s. But I > think > this is a "dirty" solution, and not what I want. > > Thanks, for your suggestions anyway. Maybe you got asnother idea?? > > Thanks. > > Greets Alex > > On 16 Aug., 14:49, André Moraes <andr...@gmail.com> wrote: > > > This aproach will not work, since after compiled GWT generates pure > > JavaScript. > > > You could do the following: > > > 1- Create an JSP page (index.jsp) and use this page as your GWT hosted page. > > 2- When rendering the page, check the name of the module (not the name of > > the class) that you want to load. > > 3- Create one Module.gwt.xml file for each of the user interface that you > > want to load. > > 4- When renderinhg the script tag that loads your selection script, change > > the name of your selection script based on the information that you > > retreived from the datastore. > > > This options generate lots of files in your GAE application, because each UI > > will be compiled independ of another, but its fast. > > > Another option will be: > > > 1- Write your GWT application with all the UI and only one entry point > > class. > > 2- Create an jsp and define a cookie with the name (not the classname, GWT > > doesn't have reflection) of the UI that you want to load. > > 3- Inside your onModuleLoad function, write a series of if's that will check > > this cookie and load the UI that you want. > > 4- Use the GWT.async (code-splitting) to load the UI that you want, this > > will cost another round-trip but will download much less code. If you don't > > do that, the browser will download all the code for all the UI. > > > Hope it helps. > > > -- > > André Moraes > > Analista de Desenvolvimento de Sistemas > > andr...@gmail.comhttp://andredevchannel.blogspot.com/ > > -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.