<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from rtf -->
<style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<font face="Arial, sans-serif" size="2">
<div>Is this possible to display each individual item so I can still check/uncheck them using my below code, or can I use a different GeoExt/Ext container to accomplish this? I need to keep the layers grouped because of performance but I still need to be able
to display each individual layer so that I can turn them on/off. Is this possible? Any example/help immensely appreciated.</div>
<div> </div>
<div> </div>
<div>My layer group is declared as the following -</div>
<div> </div>
<div> // Base Group Layers</div>
<div> var layer_Base = new OpenLayers.Layer.WMS("Base Layers", "<a href="http://localhost/WebService/Request.aspx"><font color="#0000FF"><u>http://localhost/WebService/Request.aspx</u></font></a>",</div>
<div> {</div>
<div> layers: ['Bridge,Rural_Highway,Highway,Arterial,Street_Segment, Street_Secondary_Segment, City_Boundary, Hydrology,Neighbourhood_Area__clear_,Neighbourhood_Boundary,Major_Parks,Neighbourhood_Parks,Recreation_Sites,School_Sites,Linear_Parks,Section_Lines,Rural_Block_Line,Rural_Lot_Line'],</div>
<div> VERSION: "1.1.1",</div>
<div> transparent: true</div>
<div> },</div>
<div> { isBaseLayer: false,</div>
<div> singleTile: true,</div>
<div> buffer: 4</div>
<div> }</div>
<div> );</div>
<div> </div>
<div> </div>
<div>Then I define my Treenode root and treepanel, and create a GeoExt LayerContainer to load the layer into the root node. Can the layers above be displayed as individual items with separate checkboxes somehow?</div>
<div> </div>
<div> var layerRoot_Legend = new Ext.tree.TreeNode({</div>
<div> enableDD: true,</div>
<div> text: "All Legend Items",</div>
<div> loaded: true,</div>
<div> expanded: true</div>
<div> });</div>
<div> </div>
<div> var layerTree_Legend = new Ext.tree.TreePanel({</div>
<div> title: '',</div>
<div> root: layerRoot_Legend,</div>
<div> enableDD: true,</div>
<div> applyLoader: true,</div>
<div> rootVisible: false</div>
<div> });</div>
<div> </div>
<div> </div>
<div>//Base layerList</div>
<div> layerList_Base = new GeoExt.tree.LayerContainer({</div>
<div> text: 'Base',</div>
<div> layerStore: mapPanel.layers,</div>
<div> leaf: false,</div>
<div> enableDD: true,</div>
<div> cls: 'rootnode',</div>
<div> singleClickExpand: true,</div>
<div> expanded: false,</div>
<div> checked: false,</div>
<div> listeners: {</div>
<div> 'checkchange' : function(node, checked)</div>
<div> {</div>
<div> // If a parent node is unchecked, uncheck all the children</div>
<div> if (node.getUI().isChecked()) {</div>
<div> node.expand();</div>
<div> node.eachChild(function(child){</div>
<div> child.ui.toggleCheck(true);</div>
<div> });</div>
<div> }</div>
<div> if (!node.getUI().isChecked())</div>
<div> {</div>
<div> node.expand();</div>
<div> node.eachChild(function(child) {</div>
<div> child.ui.toggleCheck(false);</div>
<div> });</div>
<div> }</div>
<div> }</div>
<div> },</div>
<div> loader: </div>
<div> {</div>
<div> filter: function(record) </div>
<div> { </div>
<div> if (record.data.title == 'Base Layers')</div>
<div> return true; </div>
<div> }</div>
<div> }</div>
<div> });</div>
<div> </div>
<div> </div>
<div> layerRoot_Legend.appendChild(layerList_Base);</div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
</font>
<DIV><P><HR>
This e-mail is intended for the original recipient(s) only. If you have received it in error, please advise the sender and delete this message.
</P></DIV>
</body>
</html>