1 Reply Latest reply on Apr 21, 2011 10:12 AM by Flex harUI

    Referencing state-specific properties in AS

    emarket101

      I am having trouble accessing state-specific properties in actionscript in a custom button skin.

       

      For example, in the updateDisplayList function I can reference the color of a gradiant (gr1) like this:

       

      var f1:uint = getStyle("firstFill");

      if (firstFill != f1) {
      firstFill = f1;
      gr1.color = firstFill;
      }

       

      However I can't figure out how to reference the over state of the same. In other words, this causes an error:

       

      var f1:uint = getStyle("firstFill");

      if (firstFill != f1) {
      firstFill = f1;
      gr1.color.over = firstFill;
      }

       

      Any help here would be much appreciated.