You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Mike Shaw <m1...@yahoo.com> on 2006/07/26 17:48:17 UTC

Tree2 refresh problem

Hi,

I'm posting this second time. 
I'm trying to use tree2 component in my one frame. When user clicks on a
tree menu link, I want to display info into second frame. 
I do not want my tree to get full refreshed every time user clicks on a
link. 
I think because of full refresh, browser is running out of memory. 
I'm thinking to use tigra java script tree menu if I can not find any better
solution.

I will appreciate, if anybody can help me with this problem with better
approach/suggestions

Regards
Mike
-- 
View this message in context: http://www.nabble.com/Tree2-refresh-problem-tf2004577.html#a5505775
Sent from the MyFaces - Users forum at Nabble.com.


Re: Tree2 refresh problem

Posted by Mike Shaw <m1...@yahoo.com>.
do you have any jsf example with frames? 

I just want to make sure, I'm using correctley

my main frame is like this:
main.jsp

<html>
<framset cols="30%,*">
<frame src="leftTree.jsf" name="left">
<frame src="right.jsf" name="theFrame">
</frameset>
</html>

in a leftTree.jsp

<f:facet name="document">
<h:commnadLink immediate="true" target="theFrame" action="action1">
<t:updateListener property="#{testBean.val1}" value="#{node.description}"/>
...

right.jsp

<h:outputText value="#{testBean.val1}"/>..


config.xml

<from-outcome>action1</..>
<to-view-id>right.jsf</..>


<managed-bean-name> testBean</..>
<managed-bean-scope>request..

<managed-bean-name>leftTreBean</..>
<managed-bean-scope>session..









-- 
View this message in context: http://www.nabble.com/Tree2-refresh-problem-tf2004577.html#a5511570
Sent from the MyFaces - Users forum at Nabble.com.


Re: Tree2 refresh problem

Posted by Mike Shaw <m1...@yahoo.com>.
ok, I got 1.1.2 and it fixed my problem. Now it is working fine

thanks for your help

Mike
-- 
View this message in context: http://www.nabble.com/Tree2-refresh-problem-tf2004577.html#a5512977
Sent from the MyFaces - Users forum at Nabble.com.


Re: Tree2 refresh problem

Posted by Andrew Robinson <an...@gmail.com>.
Frames + server state saving + 1.1.1 don't work I believe. I think
Core 1.1.2 fixed the issue allowing multiple request states on the
server for each client.

On 7/26/06, Mike Shaw <m1...@yahoo.com> wrote:
>
> I'm using myfaces version 1.1.1
>
> I'm using request state on a tree bean and second frame bean
>
> state_saving_method is server
>
> tree example is a client tree
> --
> View this message in context: http://www.nabble.com/Tree2-refresh-problem-tf2004577.html#a5510729
> Sent from the MyFaces - Users forum at Nabble.com.
>
>

Re: Tree2 refresh problem

Posted by Mike Shaw <m1...@yahoo.com>.
I'm using myfaces version 1.1.1

I'm using request state on a tree bean and second frame bean

state_saving_method is server

tree example is a client tree
-- 
View this message in context: http://www.nabble.com/Tree2-refresh-problem-tf2004577.html#a5510729
Sent from the MyFaces - Users forum at Nabble.com.


Re: Tree2 refresh problem

Posted by Andrew Robinson <an...@gmail.com>.
Sounds as if you have a scope issue. Make sure your tree model stays
loaded. I usually use Seam's conversation state or JSF's session
state, but you may need request scope. If so, you probably need
t:saveState to persist your tree model. Also what myfaces version are
you using and what state saving type (client or server)?

-Andrew

On 7/26/06, Mike Shaw <m1...@yahoo.com> wrote:
>
> Now I'm seeing very strange problem..
>
> when I click first time on a link, it displays a node name correctley on a
> second frame
>
> when I click second time on any link, it displays whole tree into second
> frame
>
> when I click third time, it displays a node name correctley
>
>
> --
> View this message in context: http://www.nabble.com/Tree2-refresh-problem-tf2004577.html#a5510516
> Sent from the MyFaces - Users forum at Nabble.com.
>
>

Re: Tree2 refresh problem

Posted by Mike Shaw <m1...@yahoo.com>.
Now I'm seeing very strange problem..

when I click first time on a link, it displays a node name correctley on a
second frame

when I click second time on any link, it displays whole tree into second
frame

when I click third time, it displays a node name correctley


-- 
View this message in context: http://www.nabble.com/Tree2-refresh-problem-tf2004577.html#a5510516
Sent from the MyFaces - Users forum at Nabble.com.


Re: Tree2 refresh problem

Posted by Andrew Robinson <an...@gmail.com>.
Why would the tree get refreshed at all if you are using frames and 'target'?

<t:tree2...>
  <f:facet name="node">
    <h:commandLink target="theFrame" action="openNode">
      <t:updateActionListener ... />
    </h:commandLink>




On 7/26/06, Mike Shaw <m1...@yahoo.com> wrote:
>
> Hi,
>
> I'm posting this second time.
> I'm trying to use tree2 component in my one frame. When user clicks on a
> tree menu link, I want to display info into second frame.
> I do not want my tree to get full refreshed every time user clicks on a
> link.
> I think because of full refresh, browser is running out of memory.
> I'm thinking to use tigra java script tree menu if I can not find any better
> solution.
>
> I will appreciate, if anybody can help me with this problem with better
> approach/suggestions
>
> Regards
> Mike
> --
> View this message in context: http://www.nabble.com/Tree2-refresh-problem-tf2004577.html#a5505775
> Sent from the MyFaces - Users forum at Nabble.com.
>
>