Re: Tomcat deploy problem related to tapestry-cometd

2012-12-31 Thread Taha Siddiqi
Hi It is a tomcat7 and Atmosphere issue. This might help https://groups.google.com/forum/?fromgroups=#!topic/atmosphere-framework/_qgyQ1BJK_Y regards Taha On Jan 1, 2013, at 5:09 AM, bhorvat wrote: > I have got a following problem that I am not sure how to solve. I believe > that there is som

Tomcat deploy problem related to tapestry-cometd

2012-12-31 Thread bhorvat
I have got a following problem that I am not sure how to solve. I believe that there is some dependency incompatiblity problem, but I dont know how to check. Does anyone have any idea where to start? I am using maven to manage my dependencies. The dependancy that I think is the root of the proble

Re: Access "this" page object from the template

2012-12-31 Thread Bob Harner
Yeah, I'm pretty sure that's fixed in one of the style tweaks I made a few weeks back, but there hasn't been a release since then. On Mon, Dec 31, 2012 at 9:28 AM, Michael Gentry wrote: > An "interesting" documentation glitch is the header for the > ComponentResourcesCommon > (and Locatable) box

Re: Access "this" page object from the template

2012-12-31 Thread Michael Gentry
An "interesting" documentation glitch is the header for the ComponentResourcesCommon (and Locatable) box reads like this (at least in Chrome): "Methods inherited from interface org.apache.tapestry5." "ComponentResourcesCommon" is a hyperlink in the same color as the box background, so you don't s

Re: Access "this" page object from the template

2012-12-31 Thread fmaylinch
bobharner wrote > By the way, just in case it helps someone. We have many pages passing "this" page to the components. Now I know it can be retrieved using ComponentResources. But, in order to avoid changing everything at once, I figured out a way to let my component receive the page parameter (s

Re: Access "this" page object from the template

2012-12-31 Thread fmaylinch
fmaylinch wrote > It's strange because ComponentResources doesn't seem to have that > property: Oh yes it does; it comes from ComponentResourcesCommon. -- View this message in context: http://tapestry.1045711.n5.nabble.com/Access-this-page-object-from-the-template-tp5719073p5719080.html Sent f

Re: Access "this" page object from the template

2012-12-31 Thread fmaylinch
bobharner wrote > Per http://tapestry.apache.org/link-components-faq.html it's pretty > easy to generate a link to the current page: > > refresh page > > Similarly, you should be able to do this: > Thanks! It's strange because ComponentResources doesn't seem to have that property: http://tape

Re: Access "this" page object from the template

2012-12-31 Thread Bob Harner
Per http://tapestry.apache.org/link-components-faq.html it's pretty easy to generate a link to the current page: refresh page Similarly, you should be able to do this: On Mon, Dec 31, 2012 at 7:40 AM, fmaylinch wrote: > Chris Poulsen wrote >> Would it not be easier to simply inject Component

Re: Access "this" page object from the template

2012-12-31 Thread fmaylinch
Chris Poulsen wrote > Would it not be easier to simply inject ComponentResources in your > component class and use it for current page? Thanks! I didn't thought of that... -- View this message in context: http://tapestry.1045711.n5.nabble.com/Access-this-page-object-from-the-template-tp5719073

Re: select blankOption

2012-12-31 Thread Chris Poulsen
Hi, To me this looks like your problem is that you have a getters with side-effects? ( getUsers() for example ). What if you set up your page-instance variables prior to rendering (not during - take a look at page lifecycle phases), then you could determine your blank option and retrieve/cache yo

Re: customising t:tree icons

2012-12-31 Thread Lance Java
You might need to raise a jira for this. There's a TODO in the TreeNode source: // TODO: Some way to influence the rendered output (i.e., to display different icons based on file type). As a workaround, you could hide the existing icons and provide "label" and "value" parameters to the tree. The t

Re: Access "this" page object from the template

2012-12-31 Thread Chris Poulsen
Hi, Would it not be easier to simply inject ComponentResources in your component class and use it for current page? -- Chris On Mon, Dec 31, 2012 at 12:26 PM, fmaylinch wrote: > Hello, > > This might be a stupid question but... can we access the page object from > the template (to pass it to

Access "this" page object from the template

2012-12-31 Thread fmaylinch
Hello, This might be a stupid question but... can we access the page object from the template (to pass it to a component, for example). Now we define a getPage method: // MyPage.java class MyPage { public MyPage getPage() { return this; } } // MyPage.tml Can we do something like this t

Re: implementing a Tapestry IoC annotation to cache method results

2012-12-31 Thread Lance Java
The "watch" parameter will reset the cache if another property changes. Consider a loop: ${transformedItem.someProperty} public class MyPage @Property private Item item; public List getItems() { ... } @Cached(watch="item") public TransformedItem getTransformedItem

customising t:tree icons

2012-12-31 Thread John
I'd like to be able to choose the icon (css class) of individual tree nodes in my model. Is that possible? I have a number of different node types and want to choose other than the directory/file icons that the tree component comes with out of the box. John

Re: implementing a Tapestry IoC annotation to cache method results

2012-12-31 Thread John
thanks, that could do the job - but is there any example of using the watch parameter? - Original Message - From: Lance Java To: users@tapestry.apache.org Sent: Monday, December 31, 2012 8:49 AM Subject: Re: implementing a Tapestry IoC annotation to cache method results Ar

Re: implementing a Tapestry IoC annotation to cache method results

2012-12-31 Thread Lance Java
Are you aware of the @Cached annotation? When used on a component/page method, only the first invocation will invoke the method. Subsequent calls will use a cached value. http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/annotations/Cached.html http://tapestry.apache.org/tapestry5/

Re: select blankOption

2012-12-31 Thread John
consider the following example When the select component is rendered the call to getUOption precedes the call to getUserSelectModel so the uOption state is not yet set. public BlankOption getUOption() { return uOption? BlankOption.ALWAYS:BlankOption.NEVER; } pu