1 Reply Latest reply on Mar 26, 2009 11:22 AM by jose3

    ConstraintRows sibling-relative layout problem

    jose3 Level 1
      I am having problems creating constraintRows by means of ActionScript with sibling-relative layouts aaplied to a Canvas. I get a height wich is less than the one set.

      Here is a code in AS3 (not working) for generating two rows, Row1 and Row2.


      consRow = new ConstraintRow();

      consRow.initialized(this, "Row1");

      consRow.height = 36;


      consRow = new ConstraintRow();

      consRow.initialized(this, "Row2");


      The first one with a fixed height of 36, the second adjusts to the rest of the available space of the container, according to the MXML example shown here. The problem is that the first row has an end result of height=19, while if I watch the expression of the array only explicitHeight=36 and not the real height.

      Below there is an MXML sample where the first row has a fixed size and the second one adjusts. This is to compare both AS3 and MXML.


      <mx:ConstraintRow id="Row1" height="36" />
      <mx:ConstraintRow id="Row2" />

      If anybody can see what I am doing wrong please let me know.

      Thanks very much in advance,