<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div>Thanks!! Does it show the same icon for all the nodes? would it be possible to show differente image for each node?</div><div><br></div><div>Thanks again</div><div><br>El 11/09/2014, a las 19:25, <<a href="mailto:dustin.r.blankenship@accenturefederal.com">dustin.r.blankenship@accenturefederal.com</a>> escribió:<br><br></div><blockquote type="cite"><div>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:UICTFontTextStyleBody;
        panose-1:0 0 0 0 0 0 0 0 0 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">This is how we’ve done it:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">var layerTreeStore = Ext.create('Ext.data.TreeStore', {<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> model: 'GeoExt.data.LayerTreeModel',<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> root: {<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> expanded: true,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> plugins: [{<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> ptype: 'gx_layercontainer',<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> loader: {<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> baseAttrs: {<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> iconCls: 'eventNodeIcon'<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> },<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> store: layerStore<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> }<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> }]<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> }<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> });<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Where the “eventNodeIcon” is a css class that uses a background image. For us it’s just blank.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> <a href="mailto:users-bounces@geoext.org">users-bounces@geoext.org</a> [<a href="mailto:users-bounces@geoext.org">mailto:users-bounces@geoext.org</a>]
<b>On Behalf Of </b><a href="mailto:dustin.r.blankenship@accenturefederal.com">dustin.r.blankenship@accenturefederal.com</a><br>
<b>Sent:</b> Thursday, September 11, 2014 11:25 AM<br>
<b>To:</b> <a href="mailto:jcarrascog@gmail.com">jcarrascog@gmail.com</a><br>
<b>Cc:</b> <a href="mailto:users@geoext.org">users@geoext.org</a><br>
<b>Subject:</b> Re: [Users] Change Image Icon for layers nodes in TreePanel GeoExt 1.1<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt">We have done this I will get you a sample in an hour<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:"UICTFontTextStyleBody","serif"">Dustin Blankenship<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:"UICTFontTextStyleBody","serif"">Sr. Software Developer <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:"UICTFontTextStyleBody","serif"">Accenture<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:"UICTFontTextStyleBody","serif"">407 S Pennsylvania Ave<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:"UICTFontTextStyleBody","serif"">Joplin MO 64836<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:"UICTFontTextStyleBody","serif"">417-793-3889<o:p></o:p></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.5pt;font-family:"UICTFontTextStyleBody","serif""><o:p> </o:p></span></p>
</div>
<p class="MsoNormal">Sent from my iPhone<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><br>
On Sep 11, 2014, at 11:23, "Joaquin Carrasco Gallego" <<a href="mailto:jcarrascog@gmail.com">jcarrascog@gmail.com</a>> wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<div>
<p class="MsoNormal">Hi everyone, I am trying to change the image icon of a layer node in a
<br>
TreePanel but always shows me the default one of the class <br>
".x-tree-node-leaf .x-tree-node-icon". Searching for Internet in some <br>
pages the createNode function is mention in a loader, but I am trying it <br>
and it doesn´t works. Some help is appreciated. Here is my code:<br>
<br>
<br>
var treeConfig = [ {<br>
nodeType : "gx_baselayercontainer",<br>
text : "Ortofotos"<br>
}, {<br>
nodeType : "gx_overlaylayercontainer",<br>
text : "Capas Vectoriales",<br>
expanded : true,<br>
// render the nodes inside this container with a radio <br>
button,<br>
// and assign them the group "foo".<br>
loader : {<br>
baseAttrs : {<br>
radioGroup : "foo",<br>
uiProvider : "layernodeui",<br>
},<br>
createNode: function(attr) {<br>
attr.iconCls = "nuevaClase";<br>
return <br>
GeoExt.tree.LayerParamLoader.prototype.createNode.apply(this, attr);<br>
}<br>
}<br>
} ];<br>
<br>
Thanks!!!<br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@geoext.org">Users@geoext.org</a><br>
<a href="http://www.geoext.org/cgi-bin/mailman/listinfo/users">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a><o:p></o:p></p>
</div>
</blockquote>
</div>
</div></blockquote></body></html>