[
https://issues.apache.org/jira/browse/TAPESTRY-394?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12516081
]
Ben Dotte commented on TAPESTRY-394:
------------------------------------
I've got this implemented locally for components that have a required listener
(XTile, DirectLink, InvokeListener, Suggest) but it isn't clear to me how or
whether this should be used for components with non-required listeners. How
would you tell if the user doesn't want a listener vs. assuming an implicit
one? I suppose we could look for a listener and fail silently if we don't find
one (for components with non-required listeners) but that seems less than ideal.
> Default for listener parameter of DirectLink, etc.
> --------------------------------------------------
>
> Key: TAPESTRY-394
> URL: https://issues.apache.org/jira/browse/TAPESTRY-394
> Project: Tapestry
> Issue Type: New Feature
> Components: Framework
> Affects Versions: 4.0
> Reporter: Howard M. Lewis Ship
> Assignee: Ben Dotte
> Priority: Minor
> Fix For: 4.1.3
>
>
> The following is a common convention in Tapestry:
> <p>
> <a href="#" jwcid="[EMAIL PROTECTED]" listener="listener:doClear">clear
> counter</a>
> </p>
> Looking at this, it seems to me that the default for listener could be
> calculated; that is, capitalize the component id to "Clear" and prefix with
> "do".
> I.e.
> getContainer().getListeners().getListener("do" + capitalize(getId()));
> Of course, for auto-generated ids, this would be a failure (either no
> listener found, or something more explicit).
--
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]