我是参考unity做的Horizontal和Vertical两个布局模式。支持前向对齐,后向对齐,居中,拉伸,按内容收缩,LayoutElement。
github:https://github.com/hubluesky/CocosLayout