<div>I tested ...</div>
<div>Thats working now...</div>
<div> </div>
<div>Thanks !</div>
<div> </div>
<div>Paul<br><br></div>
<div class="gmail_quote">On Fri, Dec 11, 2009 at 3:15 PM, Andreas Hocevar <span dir="ltr"><<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>></span> wrote:<br>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">Thanks for your investigation.<br><br>I have created a patch based on your findings. Can you please test if<br>
the patch attached to <a href="http://trac.geoext.org/ticket/186" target="_blank">http://trac.geoext.org/ticket/186</a> also fixes your<br>issue and report back?<br><br>Regards,<br>Andreas.<br><br>On 2009-12-11 18:25, Paul james wrote:<br>
> Thanks...<br>> It愀 working now...<br>
<div class="im">> I added that code in contructor<br>> ...<br>> for (i=0;i< mapPanel.layers.map.layers.length;i++)<br>> {<br>> if(mapPanel.layers.map.layers[i].name == config.layer)<br>
> {<br>> this.allItems =<br>> mapPanel.layers.map.layers[i].params.LAYERS;<br>> break;<br>> }<br>> }<br>> ...<br>> And removed<br>> this.allItems = this.getItems()<br>
> from render method...<br>><br>> Paul<br>> On Thu, Dec 10, 2009 at 4:14 PM, Andreas Hocevar <<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a><br></div>
<div class="im">> <mailto:<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>>> wrote:<br>><br>> On 2009-12-10 19:11, Paul james wrote:<br>>> Thanks Andreas...<br>>> But I dint get that...<br>
</div>>> I惴 trying figure out how that allItems array and method<br>
<div class="im">>> onCheckChange should work, without success..<br>>> That bug occurs always that I have a sublayer with checked true<br>>> and two or more sublayers with checked false...<br>
>><br>>> Please please help me :(<br>><br>> There are two solutions I can think of:<br>><br>> * provide allItems in the configuration instead of using<br>> getItems() in the render method (in LayerParamNode.js).<br>
><br>> * determine allItems before the node is rendered. Either in the<br>> node constructor (if layer provided as object) or in a listener<br>> for the layerStore's update event.<br>><br>> The latter is obviously more elegant, but more effort to implement.<br>
><br>> Regards,<br>> Andreas.<br>><br>>><br>>> Paul<br>>><br>>><br>>> On Wed, Dec 9, 2009 at 6:08 AM, Andreas Hocevar<br></div>
<div>
<div></div>
<div class="h5">>> <<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a> <mailto:<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>>> wrote:<br>>><br>>> Hi,<br>
>><br>>> I guess the problem is that allItems will be set incorrectly<br>>> for some<br>>> layers. My patch calls onCheckChange when it finds a checked<br>>> attribute<br>
>> on the layer node. If this is set to false, it will turn off<br>>> the layer,<br>>> removing the layer from the params. Layers that get created<br>>> after that<br>
>> will miss that layer in their allItems array.<br>>><br>>> I don't have time to look for a solution now, but maybe the<br>>> information<br>>> above is enough for you to figure out one.<br>
>><br>>> Regards,<br>>> Andreas.<br>>><br>><br>><br>> --<br>> Andreas Hocevar<br>> OpenGeo - <a href="http://opengeo.org/" target="_blank">http://opengeo.org/</a><br>
> Expert service straight from the developers.<br>><br>><br>><br><br><br>--<br>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>