You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Howard M. Lewis Ship (JIRA)" <de...@tapestry.apache.org> on 2007/06/25 02:35:26 UTC

[jira] Commented: (TAPESTRY-1457) Setting empty activation context

    [ https://issues.apache.org/jira/browse/TAPESTRY-1457?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12507739 ] 

Howard M. Lewis Ship commented on TAPESTRY-1457:
------------------------------------------------

I'm having to change the various createPageLink() methods (it's in a couple of different interfaces, due to Law of Demeter) ... anyway, adding an boolean override parameters which can be set to true to indicate "use the supplied context even when empty."  Eventually, that will be tied to the ActionLink's context parameter, as in resources.isBound().

> Setting empty activation context
> --------------------------------
>
>                 Key: TAPESTRY-1457
>                 URL: https://issues.apache.org/jira/browse/TAPESTRY-1457
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Core Components
>    Affects Versions: 5.0.3
>            Reporter: Peter
>            Assignee: Howard M. Lewis Ship
>
> It isn't possible to set an empty context using 'contex' parameter of PageLink. It always treats null and zero length array/list in the same way - asks the page about its activation context via onPassivate. I think that only null should trigger onPassivate.
> Example
> <a t:type="PageLink" page="test" context="context">page link</a>
> public Object[] getContext()
> {
> 	if (test == 0)
> 		return new Object[] {"1", "2"};	// context will be ../test/1/2
> 	else
> 		if (test == 1)
> 			return new Object[0];	// onPassivate will be asked but context should be empty IMO
> 		else
> 			return null;	// onPassivate will be asked, ok
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org