[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.rt.riena] Re: where to do the remote service call

Thanks! Both work fine.

Thanks,

Sjoerd

"Christian Campo" <christian.campo@xxxxxxxxxxxx> wrote in message news:4A1164AC.9000503@xxxxxxxxxxxxxxx
Hi Sjoerd,

you can use the NavigationNodeListener for a number of different event you get for the nodes. For the problem that you describe you might as well overwrite the method afterBind in the SubModuleController (make sure you call super.afterBind()) and that method "afterBind" gets called each and every time that SubModule is activated.

cheers
christian


Thorsten Schenkel schrieb:
Hi Sjoerd,

you can add to every node of the navigation a listener (NavigationNodeListener).
So you will be informed after every change of status of the navigation node.


example:


@Override public void setNavigationNode(ISubModuleNode navigationNode) {

    super.setNavigationNode(navigationNode);

    getNavigationNode().addListener(new SubModuleNodeListener() {
        @Override
        public void afterDeactivated(ISubModuleNode source) {
            super.afterDeactivated(source);
            getStatusLine().clear();
        }
    });
}

greetings

Thorsten


Sjoerd Kessels schrieb:
Hi,

I have a view and corresponding controller that displays a list of projects. In the controller's configureRidgets() method I placed the call to the remote service that returns the list of projects. This works.
However the second time I open the view via the navigation menu the configureRidgets() method is not called anymore, which makes sense. So my view is not repopulated.


What would be the best place to place my remote service call so I am able to call it every time the view (navigationnode) gets activated while still being able to ge to the controller to update the model that is bound to the table?

Is there something like a listener of navigationnodes? And where would I place the listener?

Thanks,

Sjoerd