<div>Thats right !</div>
<div> </div>
<div>About my other problem (Change sublayer label on treeview) ...</div>
<div>I tried with that :</div>
<div> </div>
<div>tree.on(&#39;beforeappend&#39;, function(tree, parent, node){ </div>
<div>  node.text = &quot;test&quot;;</div>
<div> });</div>
<div> </div>
<div>It only changes the last child... Can you help me on that?</div>
<div> </div>
<div>Thanks...</div>
<div> </div>
<div>Paul</div>
<div><br><br> </div>
<div class="gmail_quote">On Fri, Oct 2, 2009 at 4:58 PM, Andreas Hocevar <span dir="ltr">&lt;<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>&gt;</span> wrote:<br>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">Hey-<br><br>one note on Format.JSON::write: I only used this in the tree.js example<br>to provide a means of changing the tree configuration via the user<br>
interface. This is nothing that you would do in a real-life application.<br><br>Lazy loading of JSON configurations from a remote server is a different<br>story, and Ext helps us a lot with it. nodeTypes are for loading<br>
different nodes, and for customized UIs, you can provide a list of<br>uiProviders with the tree&#39;s default loader.<br>
<div class="im"><br>Regards,<br>Andreas.<br><br>Paul james wrote:<br></div>
<div class="im">&gt; Update...<br>&gt; The problem was the Format.JSON().write function... It was not<br>&gt; rendering the baseAttrs method...<br>&gt; I put that inside<br>&gt;       root: {<br>&gt;             nodeType: &quot;async&quot;,<br>
&gt;             children:<br>&gt; ...<br>&gt;<br>&gt; And worked fine...<br>&gt;<br>&gt; Thanks Andreas for the great help!<br>&gt;<br>&gt; Paul<br>&gt;<br>&gt; On Thu, Oct 1, 2009 at 2:26 PM, Paul james &lt;<a href="mailto:pauljame@gmail.com">pauljame@gmail.com</a><br>
</div>
<div class="im">&gt; &lt;mailto:<a href="mailto:pauljame@gmail.com">pauljame@gmail.com</a>&gt;&gt; wrote:<br>&gt;<br>&gt;     Thanks again Andreas...<br>&gt;     I tried that code (just added cb variable)...<br>&gt;     But the radio button never shows up... No javascript error<br>
&gt;     reported as well... I think it is not entering in render function ...<br>&gt;     Any idea?<br>&gt;<br>&gt;      loader: {<br>&gt;                 param: &quot;LAYERS&quot;,<br>&gt;                 baseAttrs: {<br>
&gt;                     uiProvider: Ext.extend(Ext.tree.TreeNodeUI, {<br>&gt;                         render: function(bulkRender) {<br>&gt;                             var cb = this.checkbox; //added<br>&gt;<br>&gt;<br>
&gt;     Ext.tree.TreeNodeUI.prototype.render.apply(this, arguments);<br>&gt;                             Ext.DomHelper.insertAfter(cb, &#39;&lt;input<br>&gt;     type=&quot;radio&quot; class=&quot;gx-tree-radio&quot; name=&quot;radio&quot;&gt;&lt;/input&gt;&#39; );<br>
&gt;                         },<br>&gt;                         onClick: function(e) {<br>&gt;                             if(e.getTarget(&#39;.gx-tree-radio&#39;, 1)) {<br>&gt;                                 // do whatever you want to do when<br>
&gt;     radio button was clicked<br>&gt;                             }<br>&gt;                             else {<br>&gt;<br>&gt;     Ext.tree.TreeNodeUI.prototype.onClick.apply(this,arguments);<br>&gt;                             }<br>
&gt;                         }<br>&gt;                     })<br>&gt;                 }<br>&gt;             }<br>&gt;<br>&gt;     Paul<br>&gt;<br>&gt;     On Thu, Oct 1, 2009 at 5:35 AM, Andreas Hocevar<br></div>
<div>
<div></div>
<div class="h5">&gt;     &lt;<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a> &lt;mailto:<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>&gt;&gt; wrote:<br>&gt;<br>&gt;         Hey Paul,<br>&gt;<br>
&gt;         in the simplest case, it would look something like this:<br>&gt;<br>&gt;         nodeType: &quot;gx_layer&quot;,<br>&gt;         layer: &quot;Tasmania (Group Layer)&quot;,<br>&gt;         isLeaf: false,<br>&gt;         loader: {<br>
&gt;            param: &quot;LAYERS&quot;,<br>&gt;            baseAttrs: {<br>&gt;                uiProvider: Ext.extend(Ext.tree.TreeNodeUI, {<br>&gt;                    render: function(bulkRender) {<br>&gt;<br>&gt;          Ext.tree.TreeNodeUI.prototype.render.apply(this, arguments);<br>
&gt;                        Ext.DomHelper.insertAfter(cb,<br>&gt;                          &#39;&lt;input type=&quot;radio&quot; class=&quot;gx-tree-radio&quot;<br>&gt;         name=&quot;radio&quot;&gt;&lt;/input&gt;&#39;<br>
&gt;                        );<br>&gt;                    },<br>&gt;                    onClick: function(e) {<br>&gt;                        if(e.getTarget(&#39;.gx-tree-radio&#39;, 1)) {<br>&gt;                            // do whatever you want to do when radio<br>
&gt;         button was<br>&gt;         clicked<br>&gt;                        } else {<br>&gt;<br>&gt;         Ext.tree.TreeNodeUI.prototype.onClick.apply(this,<br>&gt;         arguments);<br>&gt;                        }<br>
&gt;                    }<br>&gt;                })<br>&gt;            }<br>&gt;         }<br>&gt;<br>&gt;         Regards,<br>&gt;         Andreas.<br>&gt;<br>&gt;         Paul james wrote:<br>&gt;         &gt; I was talking about that with Andreas :<br>
&gt;         &gt;<br>&gt;         &gt; &gt; What I tried to do :<br>&gt;         &gt; &gt; 1-) Add radio button to Group Layer ...<br>&gt;         &gt; &gt; nodeType: &quot;gx_layer&quot;,<br>&gt;         &gt; &gt;         layer: &quot;Tasmania (Group Layer)&quot;,<br>
&gt;         &gt; &gt;         isLeaf: false,<br>&gt;         &gt; &gt;         loader: {<br>&gt;         &gt; &gt;             param: &quot;LAYERS&quot;,<br>&gt;         &gt; &gt;             baseAttrs: {radioGroup: &quot;foo2&quot;}<br>
&gt;         &gt; &gt;         }<br>&gt;         &gt; &gt;<br>&gt;         &gt; &gt; That doesnt work... Radio never shows up...<br>&gt;         &gt; Andreas Hocevar:<br>&gt;         &gt;<br>&gt;         &gt; &gt; Yeah, because sub-nodes use a plain TreeNodeUI. If you<br>
&gt;         want to use these<br>&gt;         &gt; &gt; additional radio buttons, you can try to configure the<br>&gt;         LayerParamNodes<br>&gt;         &gt; &gt; with a LayerNodeUI. But I doubt that this will work out of<br>
&gt;         the box.<br>&gt;         &gt; &gt; Otherwise, it requires a custom UI. Patches for a generic<br>&gt;         &gt; &gt; additional-radio-button-UI-mixin are welcome.<br>&gt;         &gt;<br>&gt;         &gt; Now, I悲 like help, and how can I do that custom UI... Any<br>
&gt;         help will<br>&gt;         &gt; be great...<br>&gt;         &gt;<br>&gt;         &gt;<br>&gt;         &gt; Paul<br>&gt;         &gt;<br>&gt;         ------------------------------------------------------------------------<br>
&gt;         &gt;<br>&gt;         &gt; _______________________________________________<br>&gt;         &gt; Users mailing list<br></div></div>&gt;         &gt; <a href="mailto:Users@geoext.org">Users@geoext.org</a> &lt;mailto:<a href="mailto:Users@geoext.org">Users@geoext.org</a>&gt;<br>

<div class="im">&gt;         &gt; <a href="http://www.geoext.org/cgi-bin/mailman/listinfo/users" target="_blank">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a><br>&gt;         &gt;<br>&gt;<br>&gt;<br>&gt;         --<br>
&gt;         Andreas Hocevar<br>&gt;         OpenGeo - <a href="http://opengeo.org/" target="_blank">http://opengeo.org/</a><br>&gt;         Expert service straight from the developers.<br>&gt;<br>&gt;<br>&gt;<br><br><br>
</div>--<br>
<div>
<div></div>
<div class="h5">Andreas Hocevar<br>OpenGeo - <a href="http://opengeo.org/" target="_blank">http://opengeo.org/</a><br>Expert service straight from the developers.<br><br></div></div></blockquote></div><br>