Merge pull request #76 from NativeScript/zhecheva/flexbox-order

FlexboxLayout exposes a method for clearing the orders cache
This commit is contained in:
Maya Zhecheva
2017-01-12 14:25:37 +02:00
committed by GitHub

View File

@@ -518,6 +518,15 @@ public class FlexboxLayout extends ViewGroup {
return false;
}
/**
* Invalidates the cache of the orders so that they are recalculated.
*/
public void invalidateOrdersCache() {
if (this.mOrderCache != null) {
this.mOrderCache.clear();
}
}
/**
* Sub method for {@link #onMeasure(int, int)}, when the main axis direction is horizontal
* (either left to right or right to left).