Domanda

For a GWTP based MVP a typical main presenter will be revealed with this code:

@Override
protected void revealInParent() {
    RevealRootContentEvent.fire(this, this);
}

This will render the View associated with the "main presenter" in the whole browser page. Is there any way for a main presenter's view to be rendered in a specific DIV in the page only. And not the whole page?

For example:

<div id="main-presenter"></div>
È stato utile?

Soluzione

Look at nested presenters

@Override
protected void revealInParent() {
    RevealContentEvent.fire(this, MainPagePresenter.TYPE_SetMainContent,
            this);
}
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top