Select to view content in your preferred language

Table of Contents - Legend Widget for FlexViewer 2.x

187034
664
12-01-2010 07:30 AM
RobertScheitlin__GISP
MVP Emeritus
All,

Here is the next in my line of widgets for the FlexViewer 2.x.

The legend portion of this widget is the same code as my dynamic legend widget so,

IT IS FOR ARCGIS SERVER 10 OR GREATER ONLY

This is just a simple TOC Widget that includes my dynamic legend component.
This widget also includes my enhancement for map service transparency,
right click context menu for zoom to make layer visible, and my scale
dependent renderer for the TOC checkboxes.
Tags (2)
0 Kudos
664 Replies
JamesKo
Occasional Contributor
Robert,

I'm using the exact same version...what exactly does this error message mean?
0 Kudos
MauriciRuiz
Deactivated User
Dear people,
Could you tell me how to compile the Widget ?

Thanks in advance
Maurici
0 Kudos
DerrickMartin
Emerging Contributor
Is there any way to control the sort order of the layers in the widget?
0 Kudos
ShaunWeston
Frequent Contributor
In the config.xml, is there a way to expand certain layers, but not others, rather than just expanding all or not expanding all using <expanded>false</expanded>
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Shaun,

  No, it all or nothing.
0 Kudos
GiosiaPoma
Regular Contributor
Hi Robert, great job.

In my app there are some symbol that appear big in the list of layer. There is a possibility to fix height and width of images in the code (example: 5x5 pixel)?

Thank you
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Giosia,

  It would take a bit of work in several different places and several more places depending if the swatch is coming from a 10 server with SP1 or SP2. Not something I would want to recommend.
0 Kudos
GiosiaPoma
Regular Contributor
Thank you Robert for the answer.
I didn't analyze not yet your code but I've supposed that you make a request by rest service /Legend and set the Image by transforming the imageData from rest. I use now sp1 of arcgis server.

I will apreciate if you give me suggestion for big image in toc (width and height).

Thank you
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Giosia,

  I don't have a lot of time to spend on this so I'll just point you in the right direction Look in the TocMapLayerItem.as and find the loadImage function. That is where you can add code to control the image size (I have not tested any modifications like this so be sure you comment and know how to get the code back to the original state in case you break something).
0 Kudos
GiosiaPoma
Regular Contributor
Hi Robert,
I've resolved the problem. I've setted in the loadImage in TocMapLayerItem.as in the loader complete function the image.maxHeight and maxWidht to 26 like your suggestion and it's all ok!
Thank you

function(e:Event):void
    {
     image.smoothBitmapContent = true;
     image.source = e.currentTarget.content;
     image.maxHeight = 26;
     image.maxWidth = 26;
    });



Giosia,

  I don't have a lot of time to spend on this so I'll just point you in the right direction Look in the TocMapLayerItem.as and find the loadImage function. That is where you can add code to control the image size (I have not tested any modifications like this so be sure you comment and know how to get the code back to the original state in case you break something).
0 Kudos