Roberts TOC widget - not graying label string, only checkbox graying

471
4
11-17-2011 05:25 AM
by Anonymous User
Not applicable
My scaleddependent layers(child or parent) labels are not graying.  I've dug through Roberts latest TOC widget code and can't find exactly where the child labels are being grayed to track down the problem.  Checkboxes gray based on scale.  Maybe I have a style wrong, somewhere.  Can some1 or Robert point me to the where this happens in the code.  thanks   BTW - I appreciate the tremendous amount of work Robert has done in this widget and others.
Tags (2)
0 Kudos
4 Replies
RobertScheitlin__GISP
MVP Emeritus
Dan,

   The label is greyed out in the TocItemRebderer.as both in the updateDisplayList and the set data functions:

label.enabled = !tocItem.scaledependant;
0 Kudos
by Anonymous User
Not applicable
Robert, Ok, let's try a different approach - how would I make them blue instead of gray?  I see the snippet makes the label enabled with a boolean and the next line comments out a blendmode.  And, in the checkBoxScaleDependent.as - A public function "set scaledependant" it appears to handle the check box style.  Sorry, I can't figure this one out.  Where and how is the grey actually applied.  thanks again




Dan,

   The label is greyed out in the TocItemRebderer.as both in the updateDisplayList and the set data functions:

label.enabled = !tocItem.scaledependant;
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Dan,

   I am not sure about the blue... The gray is applied by Adobe when a component like the label is disabled.
0 Kudos
PeterPuck
New Contributor
It can be changed by custom CSS entry, like this:

#myLabel{
disabledColor: 0xffffff;
}
0 Kudos