You need to log in before you can comment on or make changes to this bug.
The LegendTemplate widget currently contains code to control layer visibility, there is no way to turn this off. The impact is that if the legend template does not contain the appropriate layer visibility checkboxes, or it is used in conjunction with a popup widget that does change layer visibility, then unexpected things happen to layer visibility (like changes made in popups are lost). The proposed change is to add an attribute to the legendtemplate widget that would control whether the widget will attempt to set layer visibility or not. Turning this off would fix interaction with other widgets, or with templates that don't contain layer visibility controls at all.
fix for the next beta release
Please set the target.
*** Bug 423 has been marked as a duplicate of this bug. ***
thinking about this, perhaps a more flexible change would be to expose the name of the form variable to use for controlling layer and group visibility. This would default to 'legendlayername' (the current hardcoded value for layers) and 'legendgroupname' (the current hardcoded value for groups). setting one or both to an empty string would effectively turn off layer visibility processing. This would also allow use of multiple templates that would present information in different ways without interferring. Comments?
on second thought I think I will just introduce the original proposed change for now.
implemented new attribute: CONTROLVISIBILITY="[true|false]" not required default is true if set to FALSE then the widget will not attempt to control visibility.
Verified on windows when looking at bug 764. Which was a duplicate of this one.
I have a question. I set the "controlvisibility" attribute to "false" the "legendtemplate" widget in the "sample_enhanced.html" and in the "tools_enhanced.html" templates. I'm expecting no control visibility for either widgets (in "sample_enhanced.html" and in the "tools_enhanced.html" templates). But the "legendtemplate" widget in the "tools_enhanced.html" widget is still controlling the visibility. What is the expected result? Also what is the expecting result if both widgets have "controlvisibility" set to "true"? Actually only the widget in the "sample_enhanced.html" template has control over visibility.
The controlvisibility parameter was not being used in non-embedded mode, I have committed a fix for this. The expected result if two legend templates are used in the same application and both control visibility is undefined and depends on a number of factors, including: * do both templates include checkboxes (named legendlayername[])? * is one embedded and one not? * what order are they in the template? These will affect which layers get turned on / off. The original problem with this was that the embedded legend superceded the popup legend. The layer state became mismatched between the application (which would retain the state of the embedded template) and the popup (which thought it had changed the layer state). This should be noted in the documentation for the legend template widget I guess.
norm this bug need to be verified and closed by Linux :) Windows has already been done using beta 3 20041022
Verified on Fedora Core 2.