Ok let try explaining everything from the top :D

I have a page called Index and in that page I have included a component
called Popup. Now this component is basically a html popup with two tapestry
links. Then I surround this component in a form and when I click the link
(the link is from the component) it submits a form. The form is then handled
in the page Index and everything is great. 

What I now need is a way to tell those two links apart.Now if I put in the
page Index method

void onSelected(){

}

it is triggered for both links. What I want is to separate and to create
this method for both links. Something like

void onSelectedFromFirstLinkID(){

}

void onSelectedFromSecondLinkID(){

}

However this doesn't work. I thing that problem is that I need like the full
ID of the link. If I just use the id of the link the method is not
triggered, if I put those two methods in the component Popup then that those
methods are called. However I need those methods to be outside of component
Popup and inside page Index (so that every page can have different behaviour
for those links)

I have also tried 

@OnEvent(value=EventConstants.SELECTED, component="popup.firstLinkId")
void test(){
}

@OnEvent(value=EventConstants.SELECTED, component="popup/firstLinkId")
void test(){
}

@OnEvent(value=EventConstants.SELECTED, component="firstLinkId")
void test(){
}

but non work. So what I need is to know what is the full name of the element
inside a component that is included in a page?

I hope I have explained it better :D












--
View this message in context: 
http://tapestry.1045711.n5.nabble.com/Handling-components-event-in-the-page-that-includes-the-component-tp4833388p4833808.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to