Anyway to programmatically animate layout weight property of linear layout

前端 未结 5 1756
暗喜
暗喜 2021-02-18 15:12

I have two views in a linear layout, I programmatically change their layout_weight property. Is there a way I could animate this change in weight so when the weight is changed v

5条回答
  •  长情又很酷
    2021-02-18 15:44

    All of the answers above weren't working for me (they would simply "snap" and not animate), but after I added weight_sum="1" to the parent layout, it started working. Just in case someone else comes up with the same issue.

提交回复
热议问题