[ http://issues.apache.org/jira/browse/BEEHIVE-478?page=history ]
     
Daryl Olander resolved BEEHIVE-478:
-----------------------------------

     Assign To: Krista Baker  (was: Daryl Olander)
    Resolution: Fixed

The code that set the root image was in an if statement that was never executed 
if the tree was being dynamically created which is the reason that the image 
was not appearing.  I fixed this.

The second change made was to report a "warning" if you set the root images on 
a Tree tag for a dynamically created tree that doesn't have ITreeRootElement as 
the root.

BVT coreweb/bugs/j478

> rootNodeCollapsedImage and ExpandedImage do not work when set in the JSP on 
> trees created in pageFlows
> ------------------------------------------------------------------------------------------------------
>
>          Key: BEEHIVE-478
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-478
>      Project: Beehive
>         Type: Bug
>   Components: NetUI
>     Versions: V1Beta
>     Reporter: Krista Baker
>     Assignee: Krista Baker
>  Attachments: j478.zip
>
> When overriding the default images on a netui TreeElement or TreeRootElement, 
> the rootNodeCollapsedImage and rootNodeExpandedImage are not being set from 
> the attributes on the <netui:tree> tag in the JSP.
> Repro:
> 1. Create a new tree in the pageFlow 
>    TreeRootElement testTree;
>     //add public set and get methods
>    testTree = new TreeRootElement("Label",false);
> 2. Add the tree from the pageFlow into the jsp and set the 
> rootNodeCollapsedImage or rootNodeExpandedImage attributes
>    <netui:tree dataSource="pageFlow.testTree" 
> rootNodeCollapsedImage="rootNode.gif" />
> 3. Run the page and notice that the rootNode settings do not appear.
> Expected Results:
>   The root node image collapsed and expanded elements should appear the same 
> as if they were set in the page flow by adding the rootNodeCollapsedImage and 
> rootNodeExpandedImage attributes to the <netui:tree> tag.
> Actual Results:
>   The root node collapsed and expanded images do not appear and the defaults 
> of rootNodeCollapse and expanded are not set or referenced either. All other 
> image icon and image overrides set on the tree tag (including imageRoot) are 
> set on the displayed tree tree.  Example: if lastNodeCollapsedImage is set 
> and the root of the tree created in the pageFlow is collapsed, the item set 
> in the <netui:tree> tag for lastNodeCollapsedImage is displayed even if the 
> dataSource object is a TreeRootElement.
> Attached Repro:  There are three trees that appear when the attributes.jsp 
> file is hit.  The first tree is a jsp tree where all image settings render as 
> expected.  The second tree is a tree created in the pageFlow (TreeRootNode), 
> all image settings except the rootNode appear.  The rootNode images default 
> to the lastNodeCollapsedImage and lastNodeExpandedImage settings.  The third 
> tree is where the rootNodeCollapsed and ExpandedImages are set in the 
> pageFlow for the TreeRootElement item.  These appear as expected when the jsp 
> is rendered.
> (The source will have to be viewed to see what the images should be, they are 
> not included in the repro case.  PuppyEyes.gif and BigSmile.gif are the 
> lastNodeCollapsed and lastNodeExpanded images.  FinishBtn.gif and BuyBtn.gif 
> are the rootNodeExpanded and rootNodeCollapsed images respectively.)
> Workaround:  Use the setRootNodeCollapsedImage(String pic) or 
> setRootNodeExpandedImage(String pic) to set the images on the root node icon 
> for a tree created in the pageFlow using TreeRootElement items.  (NOTE: if 
> the imageRoot is set in the jsp, that information will be applied to the 
> rootNodeCollapsedImage and rootNodeExpandedImage items that are set in the 
> page flow.)

-- 
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
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira

Reply via email to