hasRelativeHeight.clear();
needsMeasure.clear();
+ boolean equalExpandRatio = getWidget().vertical ? !isUndefinedHeight()
+ : !isUndefinedWidth();
+ for (ComponentConnector child : getChildren()) {
+ double expandRatio = getState().getChildData().get(child)
+ .getExpandRatio();
+ if (expandRatio > 0) {
+ equalExpandRatio = false;
+ break;
+ }
+ }
+
for (ComponentConnector child : getChildren()) {
Slot slot = getWidget().getSlot(child);
double expandRatio = getState().getChildData().get(child)
.getExpandRatio();
- if (expandRatio == 0) {
+ if (equalExpandRatio) {
+ expandRatio = 1;
+ } else if (expandRatio == 0) {
expandRatio = -1;
}
slot.setExpandRatio(expandRatio);