You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Andreas Andreou (JIRA)" <ta...@jakarta.apache.org> on 2006/05/08 20:53:22 UTC
[jira] Commented: (TAPESTRY-836) XTile listener can't retrieve the
active page
[ http://issues.apache.org/jira/browse/TAPESTRY-836?page=comments#action_12378491 ]
Andreas Andreou commented on TAPESTRY-836:
------------------------------------------
The XTile service is not like any other services (Home,Page, Direct).
It does NOT activate a page. It does NOT call pageBeginRender() of your page class.
It just calls the defined listener.
I believe this is the intended behaviour.
However, you can get the name of the current page by using:
cycle.getParameter(ServiceConstants.PAGE)
> XTile listener can't retrieve the active page
> ---------------------------------------------
>
> Key: TAPESTRY-836
> URL: http://issues.apache.org/jira/browse/TAPESTRY-836
> Project: Tapestry
> Type: Bug
> Components: Contrib
> Versions: 4.0
> Environment: Tapestry 4 RC-1
> Reporter: Ben Dotte
> Assignee: Andreas Andreou
> Priority: Minor
>
> When I attempt to retrieve the active page from the request cycle in an XTile listener, it returns null:
> <span jwcid="@contrib:XTile" listener="ognl:listeners.handleCallback" sendName....>
> public void handleCallback(IRequestCycle cycle)
> {
> if (cycle == null)
> {
> System.out.println("cycle is null!");
> }
> else if (cycle.getPage() == null)
> {
> System.out.println("cycle.getPage() is null!");
> }
> }
> This returns:
> cycle.getPage() is null!
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org