|
@@ -209,6 +209,7 @@ class Flow extends Object {
|
|
var realMaxHeight : Float = -1;
|
|
var realMaxHeight : Float = -1;
|
|
var realMinWidth : Int = -1;
|
|
var realMinWidth : Int = -1;
|
|
var realMinHeight : Int = -1;
|
|
var realMinHeight : Int = -1;
|
|
|
|
+ var isConstraint : Bool;
|
|
|
|
|
|
public function new(?parent) {
|
|
public function new(?parent) {
|
|
super(parent);
|
|
super(parent);
|
|
@@ -390,6 +391,7 @@ class Flow extends Object {
|
|
override function constraintSize( width, height ) {
|
|
override function constraintSize( width, height ) {
|
|
constraintWidth = width;
|
|
constraintWidth = width;
|
|
constraintHeight = height;
|
|
constraintHeight = height;
|
|
|
|
+ isConstraint = true;
|
|
updateConstraint();
|
|
updateConstraint();
|
|
}
|
|
}
|
|
|
|
|
|
@@ -628,6 +630,14 @@ class Flow extends Object {
|
|
|
|
|
|
onBeforeReflow();
|
|
onBeforeReflow();
|
|
|
|
|
|
|
|
+ if( !isConstraint && (fillWidth || fillHeight) ) {
|
|
|
|
+ var scene = getScene();
|
|
|
|
+ if( scene.width != constraintWidth || scene.height != constraintHeight ) {
|
|
|
|
+ constraintSize(fillWidth ? scene.width : -1, fillHeight ? scene.height : -1);
|
|
|
|
+ isConstraint = false;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
var isConstraintWidth = realMaxWidth >= 0;
|
|
var isConstraintWidth = realMaxWidth >= 0;
|
|
var isConstraintHeight = realMaxHeight >= 0;
|
|
var isConstraintHeight = realMaxHeight >= 0;
|
|
// outter size
|
|
// outter size
|